S
Senapathy
VC++ .NET 2003 Standard Edition
Win XP, SP2
Hi,
I have a code that builds under VC6.0, but fails to link in VC7.1.
The offending code is as follows:
_AFX_RICHEDIT_STATE* const pEditState = _afxRichEditState;
The linker errors are:
----------------------
LVBaseDetailsView.obj : error LNK2001: unresolved external symbol
"__declspec(dllimport) class CProcessLocal<class _AFX_RICHEDIT_STATE>
_afxRichEditState"
(__imp_?_afxRichEditState@@3V?$CProcessLocal@V_AFX_RICHEDIT_STATE@@@@A)
LVBaseDetailsView.obj : error LNK2019: unresolved external symbol "public:
virtual __thiscall _AFX_EDIT_STATE::~_AFX_EDIT_STATE(void)"
(??1_AFX_EDIT_STATE@@UAE@XZ) referenced in function $L153022
LVBaseDetailsView.obj : error LNK2019: unresolved external symbol "public:
__thiscall _AFX_EDIT_STATE::_AFX_EDIT_STATE(void)"
(??0_AFX_EDIT_STATE@@QAE@XZ) referenced in function "public: static class
CNoTrackObject * __stdcall CProcessLocal<class
_AFX_RICHEDIT_STATE>::CreateObject(void)"
(?CreateObject@?$CProcessLocal@V_AFX_RICHEDIT_STATE@@@@SGPAVCNoTrackObject@@XZ)
LVBaseDetailsView.obj : error LNK2019: unresolved external symbol "public:
virtual __thiscall _AFX_RICHEDIT_STATE::~_AFX_RICHEDIT_STATE(void)"
(??1_AFX_RICHEDIT_STATE@@UAE@XZ) referenced in function "public: virtual
void * __thiscall _AFX_RICHEDIT_STATE::`scalar deleting destructor'(unsigned
int)" (??_G_AFX_RICHEDIT_STATE@@UAEPAXI@Z)
----------------------
The code above is part of legacy code, which I am porting to the .NET
compiler. I cannot drastically change the code to do away with such things
since I saw in the code documentation that this was introduced to solve some
bug where the code crashes if a find dialog is opened in a RichEdit view.
When I searched MSDN / Google I found very little information regarding
this. Later I realized it may be because _afxRichEditState is an
undocumented class, derived from the undocumented CNoTrackObject.
Does anyone know of this problem and a solution to this?
Should I link to some library explicitly in VC7 .NET?
Warm regards,
Sena
Win XP, SP2
Hi,
I have a code that builds under VC6.0, but fails to link in VC7.1.
The offending code is as follows:
_AFX_RICHEDIT_STATE* const pEditState = _afxRichEditState;
The linker errors are:
----------------------
LVBaseDetailsView.obj : error LNK2001: unresolved external symbol
"__declspec(dllimport) class CProcessLocal<class _AFX_RICHEDIT_STATE>
_afxRichEditState"
(__imp_?_afxRichEditState@@3V?$CProcessLocal@V_AFX_RICHEDIT_STATE@@@@A)
LVBaseDetailsView.obj : error LNK2019: unresolved external symbol "public:
virtual __thiscall _AFX_EDIT_STATE::~_AFX_EDIT_STATE(void)"
(??1_AFX_EDIT_STATE@@UAE@XZ) referenced in function $L153022
LVBaseDetailsView.obj : error LNK2019: unresolved external symbol "public:
__thiscall _AFX_EDIT_STATE::_AFX_EDIT_STATE(void)"
(??0_AFX_EDIT_STATE@@QAE@XZ) referenced in function "public: static class
CNoTrackObject * __stdcall CProcessLocal<class
_AFX_RICHEDIT_STATE>::CreateObject(void)"
(?CreateObject@?$CProcessLocal@V_AFX_RICHEDIT_STATE@@@@SGPAVCNoTrackObject@@XZ)
LVBaseDetailsView.obj : error LNK2019: unresolved external symbol "public:
virtual __thiscall _AFX_RICHEDIT_STATE::~_AFX_RICHEDIT_STATE(void)"
(??1_AFX_RICHEDIT_STATE@@UAE@XZ) referenced in function "public: virtual
void * __thiscall _AFX_RICHEDIT_STATE::`scalar deleting destructor'(unsigned
int)" (??_G_AFX_RICHEDIT_STATE@@UAEPAXI@Z)
----------------------
The code above is part of legacy code, which I am porting to the .NET
compiler. I cannot drastically change the code to do away with such things
since I saw in the code documentation that this was introduced to solve some
bug where the code crashes if a find dialog is opened in a RichEdit view.
When I searched MSDN / Google I found very little information regarding
this. Later I realized it may be because _afxRichEditState is an
undocumented class, derived from the undocumented CNoTrackObject.
Does anyone know of this problem and a solution to this?
Should I link to some library explicitly in VC7 .NET?
Warm regards,
Sena