LNK2001:无法解析的外部符号 "public: virtual struct CRuntimeClass *
来源:互联网 发布:淘宝当当旗舰店 编辑:程序博客网 时间:2024/05/17 12:47
今天写MFC遇到的又一个智障问题,我还是太菜
public: virtual struct CRuntimeClass * __thiscall 类名::GetRuntimeClass(void)const " (?GetRuntimeClass@类名@@UBEPAUCRuntimeClass@@XZ)
无法解析外部符号一般出现这个问题有两种情况
1. 链接库没有加载
2. 库不对,如库的调用规范(__thiscall是一种规范之一)不同,或者配置不同(有些库是win32,有些是x64的)
解决方法
1,如果在.h文件中写了DECLARE_DYNAMIC,而在.cpp文件中没有写IMPLEMENT_DYNAMIC
2,如果在.h文件中写了DECLARE_DYNCREATE ,但在.cpp文件中没有写上IMPLEMENT_DYNCREATE
总之这是个愚蠢的错误 = =
0 0
- LNK2001:无法解析的外部符号 "public: virtual struct CRuntimeClass *
- 无法解析的外部符号 "public: virtual struct CRuntimeClass
- 无法解析的外部符号 "public: virtual struct CRuntimeClass
- 无法解析的外部符号 "public: virtual struct CRuntimeClass
- 无法解析的外部符号 "public: virtual struct CRuntimeClass
- 错误:无法解析的外部符号"public:virtual struct CRuntimeClass...."
- 无法解析的外部符号 "public: virtual struct CRuntimeClass
- MFC 创建UI 线程 || 无法解析的外部符号 "public: virtual struct CRuntimeClass
- error LNK2001: 无法解析的外部符号 "public: virtual struct QMetaObject const * __thiscall Widget::metaObject
- error LNK2001: 无法解析的外部符号 "public: virtual struct QMetaObject const * __thiscall Widget::metaObject
- error LNK2001: 无法解析的外部符号 "public: virtual struct QMetaObject const * __thiscall
- error LNK2001: 无法解析的外部符号 "public: virtual struct QMetaObject const * __thiscall MainWindow::metaObje
- QT error LNK2001: 无法解析的外部符号 "public: virtual struct QMetaObject const * __thiscall Widget::metaObjec
- error LNK2001: 无法解析的外部符号 "public: virtual struct QMetaObject const * __thiscall Widget::metaObject
- error LNK2001: 无法解析的外部符号 "public: virtual struct QMetaObject const * __cdecl MainWindow::metaObject(
- error LNK2001: 无法解析的外部符号 "public: virtual struct QMetaObject const * __thiscall ****::metaObj
- vs2010+qt4编译出现error LNK2001: 无法解析的外部符号 "public: virtual struct QMetaObject等错误
- error LNK2001: 无法解析的外部符号 "public: virtual long __stdcall CBaseFilter
- 268. Missing Number
- PAT乙级1013 数素数
- Present出来的页面Push到下一页
- 【PAT】1120. Friend Numbers
- Go语言学习之运算符(The way to go)
- LNK2001:无法解析的外部符号 "public: virtual struct CRuntimeClass *
- 读《Head First设计模式》学习到的学习方法
- 【数组】Leetcode编程题解:381. Insert Delete GetRandom O(1)
- 字节流中判断消息的边界
- gcc 4.9.4 编译
- IIS部署django,CSS消失问题/无法工作
- MySql常用命令集Mysql常用命令showdatabases;显示数据库createdatab
- DDE热连接OnAdvise
- HPUOJ Triangles