CVListView由CListView派生,CPivotListView由CVListView派生,CVListView在一个MFC扩展DLL中,CPivotListView在主程序中,原先把CVListView也同样放到主程序中时没有任何错误,但我把CVListView移到了DLL中,结果build到了最后出了这样的错误:Generating Code...
Linking...
PivotListView.obj : error LNK2001: unresolved external symbol "public: virtual int __thiscall CVListView::Create(unsigned short const *,unsigned short const *,unsigned long,struct tagRECT const &,class CWnd *,unsigned int,struct CCreateContext *)" (
?Create@CVListView@@UAEHPBG0KABUtagRECT@@PAVCWnd@@IPAUCCreateContext@@@Z)
../Bin/Lc.exe : fatal error LNK1120: 1 unresolved externals
Error executing link.exe.帮忙看一下吧

解决方案 »

  1.   

    我把CVListView中的create屏蔽掉以后编译就通过了,但我还需要使用这个create,是虚函数的导出需要特殊处理吗?还是和MFC相关的虚函数导出需要特殊处理?
      

  2.   

    是不是需要那个dll的lib文件,重新连编一下呢.
      

  3.   

    我也是同样的问题,请看一下,有什么解决方法吗?
    Generating Code...
    Linking...
       Creating library Debug/EAC02A6U.lib and object Debug/EAC02A6U.exp
    EAC02A6U.obj : error LNK2001: unresolved external symbol "public: __thiscall TEAC06AProtocol::TEAC06AProtocol(void)" (??0TEAC06AProtocol@@QAE@XZ)
    /Temp/Plug-Ins/TestDll/Debug/EAC02A6U.dll : fatal error LNK1120: 1 unresolved externals
    Error executing link.exe.
    Creating browse info file...
      

  4.   

    看错误信息是没有包含,MFC的库文件(dll,lib等)
    自己查一下是否包含了必要的这些文件
      

  5.   

    mfc的库文件需要显示包含吗?需要包含什么文件呢?