Uresolver External symbol __declspec(dllimport) public: class ATL:

G

Guest

Hi,

I am trying to compile my VC6 application on VC++7. It give following linker
error.

__declspec(dllimport) public: class ATL::CStringT<unsigned short,class
StrTraitMFC_DLL<unsigned short,class ATL::ChTraitsCRT<unsigned short> > >
__thiscall CHPCmdExecFrame::GetStringParam(int,int *)"
(__imp_?GetStringParam@CHPCmdExecFrame@@QAE?AV?$CStringT@GV?$StrTraitMFC_DLL@GV?$ChTraitsCRT@G@ATL@@@@@ATL@@HPAH@Z)
referenced in function "int __cdecl CmdPlaySound(class CHPCmdExecFrame *,void
*,class CHPCpDlcWnd *)"
(?CmdPlaySound@@YAHPAVCHPCmdExecFrame@@PAXPAVCHPCpDlcWnd@@@Z)


I tried including
#include <atlstr.h>
#include <cstringt.h>

and also tried workaround given on microsoft. That is

To resolve this issue, explicitly import the template class for CStringT and
CSimpleStringT in the precompiled header (stdafx.h) file, as follows:
template class __declspec(dllimport) CStringT<TCHAR, StrTraitMFC<TCHAR,
ChTraitsCRT<TCHAR> > >;
template class __declspec(dllimport) CSimpleStringT<TCHAR>;

But this also doesn't work.

Can anyone help me to solve this issue, It's very urgent.

Thanks in advance ,
-Arun
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top