Prev: Load RTF in Word
Next: h2inc
From: Drew on 17 Dec 2009 17:37 I have an out-of-proc ATL server w/MFC support using VS2008 SP1. When the DLL is registered or instatiatiated by a client I receive two assertions during DLL_PROCESS_ATTACH. The following line in dllinit.cpp line 587 (AfxCoreInitModule()) is causing the first assertion failiure: ASSERT(AfxGetModuleState() != AfxGetAppModuleState()); If I ignore this the following line in dllmodul.cpp line 135 (InternalDllMain()) is causing the second assertion failure: VERIFY(AfxSetModuleState(AfxGetThreadState()->m_pPrevModuleState) == &afxModuleState); Is this something that can be prevented? Thanks, Drew
From: Drew on 17 Dec 2009 18:42 Oops. Make that an in-proc ATL server. "Drew" <dam(a)dam.com> wrote in message news:uuf3kn2fKHA.2104(a)TK2MSFTNGP05.phx.gbl... >I have an out-of-proc ATL server w/MFC support using VS2008 SP1. When the >DLL is registered or instatiatiated by a client I receive two assertions >during DLL_PROCESS_ATTACH. > > The following line in dllinit.cpp line 587 (AfxCoreInitModule()) is > causing the first assertion failiure: > > ASSERT(AfxGetModuleState() != AfxGetAppModuleState()); > > If I ignore this the following line in dllmodul.cpp line 135 > (InternalDllMain()) is causing the second assertion failure: > > VERIFY(AfxSetModuleState(AfxGetThreadState()->m_pPrevModuleState) == > &afxModuleState); > > Is this something that can be prevented? > > Thanks, > Drew >
From: David Ching on 17 Dec 2009 20:21 "Drew" <dam(a)dam.com> wrote in message news:OpzL3L3fKHA.1540(a)TK2MSFTNGP06.phx.gbl... > Oops. Make that an in-proc ATL server. > Are you using MFC DLL or static linking? Are you sure you have defined _USRDLL, etc. appropriately? -- David
From: Drew on 18 Dec 2009 11:05 "David Ching" <dc(a)remove-this.dcsoft.com> wrote in message news:O6H7$B4fKHA.2184(a)TK2MSFTNGP04.phx.gbl... > "Drew" <dam(a)dam.com> wrote in message > news:OpzL3L3fKHA.1540(a)TK2MSFTNGP06.phx.gbl... >> Oops. Make that an in-proc ATL server. >> > > Are you using MFC DLL or static linking? Are you sure you have defined > _USRDLL, etc. appropriately? > > -- David I am using MFC DLL. I didn't have _USRDLL defined but it didn't make any difference. I did (and do) have _AFXDLL and _WINDLL defined. Am I maybe mixing and matching these incorrectly? Thanks, Drew
From: David Ching on 19 Dec 2009 09:12 "Drew" <dam(a)dam.com> wrote in message news:ea20Cx$fKHA.2188(a)TK2MSFTNGP04.phx.gbl... > I am using MFC DLL. I didn't have _USRDLL defined but it didn't make any > difference. I did (and do) have _AFXDLL and _WINDLL defined. Am I maybe > mixing and matching these incorrectly? > What I would do is use AppWizard to create a new dummy ActiveX control and make sure you don't have the same assertion problem with this. Then copy your code into this new project. -- David
|
Pages: 1 Prev: Load RTF in Word Next: h2inc |