在VS2010中MFC扩展DLL导出CWnd的子类,外部程序调用时出现LNK2019错误,找不到构造和析构函数
在VS2010中MFC扩展DLL导出CWnd的子类,外部程序调用时出现LNK2019错误,找不到构造和析构函数,但是明明已经在CPP里定义了,并且DLL编译正常,请问怎么...
在VS2010中MFC扩展DLL导出CWnd的子类,外部程序调用时出现LNK2019错误,找不到构造和析构函数,但是明明已经在CPP里定义了,并且DLL编译正常,请问怎么办~~
#pragma once
// MyView
class MyView : public CWnd
{
DECLARE_DYNAMIC(MyView)
public:
MyView();
virtual ~MyView();
protected:
DECLARE_MESSAGE_MAP()
};
啥也没有就报错
HJJZImgViewer.obj : error LNK2019: unresolved external symbol "public: __thiscall MyView::MyView(void)" (??0MyView@@QAE@XZ) referenced in function "public: __thiscall CHJJZImgViewer::CHJJZImgViewer(class CWnd *)" (??0CHJJZImgViewer@@QAE@PAVCWnd@@@Z)
1>HJJZImgViewer.obj : error LNK2019: unresolved external symbol "public: virtual __thiscall MyView::~MyView(void)" (??1MyView@@UAE@XZ) referenced in function "public: virtual __thiscall CHJJZImgViewer::~CHJJZImgViewer(void)" (??1CHJJZImgViewer@@UAE@XZ) 展开
#pragma once
// MyView
class MyView : public CWnd
{
DECLARE_DYNAMIC(MyView)
public:
MyView();
virtual ~MyView();
protected:
DECLARE_MESSAGE_MAP()
};
啥也没有就报错
HJJZImgViewer.obj : error LNK2019: unresolved external symbol "public: __thiscall MyView::MyView(void)" (??0MyView@@QAE@XZ) referenced in function "public: __thiscall CHJJZImgViewer::CHJJZImgViewer(class CWnd *)" (??0CHJJZImgViewer@@QAE@PAVCWnd@@@Z)
1>HJJZImgViewer.obj : error LNK2019: unresolved external symbol "public: virtual __thiscall MyView::~MyView(void)" (??1MyView@@UAE@XZ) referenced in function "public: virtual __thiscall CHJJZImgViewer::~CHJJZImgViewer(void)" (??1CHJJZImgViewer@@UAE@XZ) 展开
3个回答
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询