Plugin compiled with Rhino 7 crash

Okay, so I have converted and compiled my plugin
from Rhino 6 to Rhino 7 SDK

All seems to work fine except the properties panel

dlgObjProperties::dlgObjProperties()
	: TRhinoPropertiesPanelPage<CRhinoDialog>(dlgObjProperties::IDD, IDI_ICON2, true)

The object property panel worked fine in Rhino 6
in Rhino 7 with the new compiled plugin as soon I click on the icon
on the object property toolbar Rhiino7 crashes.

Running in Debug Mode I see that the crash is somewhere in Rhino
since my breakpoints are never reached.( events in the Property page dialog )

Any hint or Idea on what to do ?

/*** PLUGIN Code ****/

void   R70PlugIn::AddPagesToObjectPropertiesDialog(CRhinoPropertiesPanelPageCollection& collection)
{
	AFX_MANAGE_STATE(AfxGetStaticModuleState());
	dlgObjProperties* page = new dlgObjProperties();
	if (nullptr != page)
		collection.Add(page);

}

GD

Nobody ?

@JohnM can you help here?

Can I have a example of a Propertypage in c++
I have made the dilaog empty and still I see a crash when I activate it in the
property toolbar

So I am afraid something coming from previous rel 6.0 i still in my project ?
Really dunno

There is an example here: rhino-developer-samples/cpp/SampleMigration/V6/SamplePropertiesPages at 7 · mcneel/rhino-developer-samples · GitHub

If you send me an example of what you are trying to do I would be happy to take a look.

Yes I will test the example and see to migrate, using that one as a template.
Will get back if still crashing, the strange thing is that I have started from that example to develop the property page and it works fine in rhino 6.
The crash happens to be somewhere in rhino even making a empty property page, do I dunno really what’s goin on. Will start from the example and see to step over.
Gd

Inviato dal mio dispositivo Huawei

-------- Messaggio originale --------

I ran the Rhino 7 Plug-in wizard and made a simple, very minimal example here: GitHub - johnmorse/PropertyPageExample

Testing your project on my laptop I see that new MFC toolset was
needed, Maybe this is the problem, using a old plugin converted
maybe the MFC toolset I am linking to is wrong, and this makes sense for the kind
of crash i see .

will check better on monday

No way to get this to work
If I get your dialog and put in my plugin I get a crash as soon
the icon is clicked.

The crash happens inside Rhino.exe so I have no clue whats wrong, checked all libraries
and they are ok.

Can you send me an example project that has the crash so I can run it?

I am moving my project under your solution to see if it works. After that will upload a simple project for testing if it still crashes.
Since my dialog uses MFC property control maybe crash it’s related to that one ? Dunno just a guess

At the End my problem is with

CMFCPropertyGridProperty and CMFCPropertyGridCtrl
Using your solution file and migrating my project I get compile errors as the above are
unrecognized. Now I am not a fan of MFC (I really hate it - but this is another story) but why these are
not compiling ?? I have searched a bit but found no help in internet on how to include the relative headers but since MFC does all the magic in the background when you make a project I have no clue what files are needed.

Any Hint here ?

gd

Hi John
The crash is related to MFC PropertyGrid Control
So If You can insert in Your simple property example a
MFC PropertyGrid Control and see if it works maybe we can find a solution

gerry

Hi John
Forget all, I have solved using your solution, I dunno how
but I solved after a cleanup

thanks
Gerry