Click to See Complete Forum and Search --> : Visual C++ .NET add MFC class problem
Signal-09
July 10th, 2003, 11:22 PM
Hello,
I have a problem in the Class Wizard for .net, which allows you to add a class based on a type.. the type is MFC, now when i input the correct information into the text fields, for choosing the name of the class, the derived class and the ID name, and i click finish it bring up a critical message box : "Object Required"
This is the first time this has happened, im not sure why.
Ive derived my class from CDialog, and i choose the correct ID resource i want it associated with.
If you need any more info please tell...
Thanks !
MfcRules
August 24th, 2003, 10:46 AM
It could be simply that your resource file has errors. Compile it explicitly to check. Otherwize:
:confused: If I have a nagging development problem, the one you mention is it. My experience has been that eventually, as my programs grow, the class wizards that adjust both rc/idl/odl and cpp/h simultaneously break. All I see now is a dialog containing "Object Required". Once the I see that message it's game over.
I've tried to re-wire the mfc markers, clean up the headers, whatever. In some cases I even have the same code with working wizards on one machine but not another. Maybe ncb/opt contains the wiring?
Anyway, I've finally lowered my head and accept the fact that eventually the mfc com and resource wizards will break, and I won't be able to re-wire them.
:) I do have a workaround that might be helpful: Create a skeleton app that uses resources and idl from your main. For example, in the same solution make a new project called AppnameWiz with similar creation settings. Then reference the .rc and idl/odl from your main project. The wizard will work even when adjusting files from your main project.
Whenever I need to do major wizard tasks like creating a CDialog, CCmdTarget or COleControl i add them through AppnameWiz.
==R
hajer
September 4th, 2003, 04:49 AM
Hello,
I'm newly user of VC .NET, i'm developping an activeX control using VC.NET, when i added some properties to my activeX, and i tried it with VB, i noticed that when i changed the properties at design time, once i launched my VB Application the properties values are cleared.
What is the problem?, could you please help me?
Hajer.
codeguru.com
Copyright WebMediaBrands Inc., All Rights Reserved.