修复Visual Studio上已存在方法的编译错误

时间:2019-09-17 07:34:44

标签: c++ visual-studio wxwidgets

我正在使用wxwidgets 3.1.2进行c ++项目,并且Visual Studio Community 2019的版本是16.2.5。我在项目中添加了the NoteBook project,现在由于出现了七个错误

Severity    Code    Description Project File    Line    Suppression State
Error   LNK2019 unresolved external symbol "public: void __thiscall wxXmlResource::AddHandler(class wxXmlResourceHandler *)" (?AddHandler@wxXmlResource@@QAEXPAVwxXmlResourceHandler@@@Z) referenced in function "public: __thiscall Notebook::Notebook(class wxWindow *,int,class wxPoint const &,class wxSize const &,long,class wxString const &)" (??0Notebook@@QAE@PAVwxWindow@@HABVwxPoint@@ABVwxSize@@JABVwxString@@@Z)  MyApp   D:\cpp\MyApp\MyApp\Notebook.obj 1   
Error   LNK2019 unresolved external symbol "public: class wxBitmap __thiscall wxXmlResource::LoadBitmap(class wxString const &)" (?LoadBitmap@wxXmlResource@@QAE?AVwxBitmap@@ABVwxString@@@Z) referenced in function "public: virtual void __thiscall clTabInfo::Colours::InitDarkColours(void)" (?InitDarkColours@Colours@clTabInfo@@UAEXXZ)   MyApp   D:\cpp\MyApp\MyApp\Notebook.obj 1   
Error   LNK2019 unresolved external symbol "public: static class wxXmlResource * __cdecl wxXmlResource::Get(void)" (?Get@wxXmlResource@@SAPAV1@XZ) referenced in function "public: virtual void __thiscall clTabInfo::Colours::InitDarkColours(void)" (?InitDarkColours@Colours@clTabInfo@@UAEXXZ)  MyApp   D:\cpp\MyApp\MyApp\Notebook.obj 1   
Error   LNK2001 unresolved external symbol "public: static class wxXmlResource * __cdecl wxXmlResource::Get(void)" (?Get@wxXmlResource@@SAPAV1@XZ)  MyApp   D:\cpp\MyApp\MyApp\notebook_bitmaps.obj 1   
Error   LNK2019 unresolved external symbol "public: __thiscall wxBitmapXmlHandler::wxBitmapXmlHandler(void)" (??0wxBitmapXmlHandler@@QAE@XZ) referenced in function "public: __thiscall Notebook::Notebook(class wxWindow *,int,class wxPoint const &,class wxSize const &,long,class wxString const &)" (??0Notebook@@QAE@PAVwxWindow@@HABVwxPoint@@ABVwxSize@@JABVwxString@@@Z)   MyApp   D:\cpp\MyApp\MyApp\Notebook.obj 1   
Error   LNK2019 unresolved external symbol "public: bool __thiscall wxXmlResource::Load(class wxString const &)" (?Load@wxXmlResource@@QAE_NABVwxString@@@Z) referenced in function "void __cdecl Notebook_Init_Bitmaps(void)" (?Notebook_Init_Bitmaps@@YAXXZ)  MyApp   D:\cpp\MyApp\MyApp\notebook_bitmaps.obj 1   
Error   LNK1120 5 unresolved externals  MyApp   D:\cpp\MyApp\MyApp\vc_mswud\MyApp.exe   1   

当我在这里查看有问题的代码时,我发现它实际上在NoteBook.cpp中 如果能解决这个问题,我将不胜感激。

0 个答案:

没有答案