AfxGetResourceHandle(); Assertion failure : MFC Extension DLL

AfxGetResourceHandle(); Assertion failure : MFC Extension DLL

Post by anand_soli » Fri, 19 Sep 2003 11:25:54


I am trying to convert parts of an MFC application to a MFC Extension
DLL. The original application is badly written. The GUI is tightly
coupled with the functionality. so i need to make an instance of this
gui object to call its funtionality. This functionality.. lets say
TESTA constantly keeps updating gui objects... i get an exception when
it tries to update its gui. so i decided to do a obj->Create() which
will create the dialog window but will not show it when the dll is
called. Here is my problem...

I need to instantiate a class that is derived from CDialog. When i say
obj->Create(...), i end up wiht an assersion failure.

de *** points to a piece of code that calls AfxGetResourceHandle();
function. When i try to call this function, it throws an assersion
failure...
handle = AfxGetResourceHandle();

any suggestions?

Thanks,
Anand.
 
 
 

1. Regular MFC dll linking to Extension MFC dll (Class Size Limit?)

2. exporting MFC class in MFC extension dlls

I have two MFC Extension dlls.

1. dll #1: export a CFormView derived class -- CAitFormView

2. dll #2: Create another CFormView derived class and
manually change its base class to CAitFormView.

When dll #2 above is linked, I get a linker unresolved
error that I don't know how to fix. I know its finding the
dll #1's library because it contains other symbols that
are resolved.

Any suggestions?

unresolved external symbol "public: static struct
CRuntimeClass const CAitFormView::classCAitFormView" (?
classCAitFormView@CAitFormView@@2UCRuntimeClass@@B
) referenced in function "protected: static struct CRun
timeClass * __cdecl CBayInventoryView::_GetBaseClass
(void)" (?
_GetBaseClass@CBayInventoryView@@KAPAUCRuntimeClas
s@@XZ)

3. AfxGetResourceHandle gives debug assertion

4. Detect if a DLL is an MFC Extension DLL

5. [ace-users] APG/Logging : Integrating ACE with regular DLLs and MFC Extension DLLs

6. MFC DLL causing assertion in calling app in realse but not debug?

7. Assertion using MFC-created regular DLL

8. using MFC in a managed application, ASSERT in AfxGetResourceHandle

9. ORA-29516: Aurora assertion failu Assertion failure at eox.c:317

10. AfxGetInstanceHandle causes assertion failure for Dll

11. ORA-29516: Aurora assertion failu Assertion failure at eox.c:317

12. CWinApp Assertion failure/ Access violation in odbc32.dll

13. Returning values from mfc-dll to non-mfc dll

14. How to change a *not use MFC* dll to *MFC shared* dll?

15. how to properly initialize an MFC Ext Dll in another MFC Ext Dll