15.obj : error LNK2005: "public: __thiscall Item_base::Item_base(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,double)" (??0Item_base@@QAE@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@s
td@@N@Z) already defined in Base_item.obj15.obj : error LNK2005: "public: virtual double __thiscall Item_base::TotalPrice(unsigned int)const " (?TotalPrice@Item_base@@UBENI@Z) already defined in Base_item.obj15.obj : error LNK2005: "public: class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > __thiscall Item_base::Get_isbn(void)const " (?Get_isbn@Item_base@@QBE?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@
std@@XZ) already defined in Base_item.objBase_item.obj : error LNK2001: unresolved external symbol "public: virtual __thiscall Item_base::~Item_base(void)" (??1Item_base@@UAE@XZ)15.obj : error LNK2001: unresolved external symbol "public: virtual __thiscall Item_base::~Item_base(void)" (??1Item_base@@UAE@XZ)
Debug/15.exe : fatal error LNK1120: 1 unresolved externals
Error executing link.exe.请问这是什么问题? 好像常发生,特别是有多个文件时
td@@N@Z) already defined in Base_item.obj15.obj : error LNK2005: "public: virtual double __thiscall Item_base::TotalPrice(unsigned int)const " (?TotalPrice@Item_base@@UBENI@Z) already defined in Base_item.obj15.obj : error LNK2005: "public: class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > __thiscall Item_base::Get_isbn(void)const " (?Get_isbn@Item_base@@QBE?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@
std@@XZ) already defined in Base_item.objBase_item.obj : error LNK2001: unresolved external symbol "public: virtual __thiscall Item_base::~Item_base(void)" (??1Item_base@@UAE@XZ)15.obj : error LNK2001: unresolved external symbol "public: virtual __thiscall Item_base::~Item_base(void)" (??1Item_base@@UAE@XZ)
Debug/15.exe : fatal error LNK1120: 1 unresolved externals
Error executing link.exe.请问这是什么问题? 好像常发生,特别是有多个文件时
解决方案 »
- 图像柱面投影实现,matlab有问题
- 指针的问题
- 新手提问:用directx回放视频问题
- 各位vc仁兄请表白 急救!!!
- 关于ListCtrl的GetItemText问题,挺怪的,大家帮我
- 我用VC作了个.ocx控件,是应用程序本地调用的,现在老板要在网页中用控件画图,我对B/S和Web编程都不熟,只好请教了:如何传大量数据给控
- 紧急送分哈:winsock不支持unicode的吗??老天,这次我惨了!
- 如何将一个.max文件中的图形分割显示啊?
- 基于视频的火焰检测(MFC)
- 请问vc++不能用初始化表对对象数组赋值吗?看看这个例程
- 关于屏幕传输的问题,高手进来帮助
- 我用了一个软件,网上下载的,怎样阻止它自动关闭?
@D@std@@V?$allocator@D@2@@std@@N@Z)Debug/15.exe : fatal error LNK1120: 2 unresolved externals
现在成这样了!
怎么就可以了呢?
谁能告诉我? 请帮帮忙! 谢谢!
.h 即头文件一般是用来被别的 .c/.cpp 文件包含, 编译器可通过它找到在其中声名的函数的实现体.
为什么 我只要引用定义类的.h文件就可以了呢?
那编译器是怎么找到类的定义的?
求教!