错误提示大致如下:
LegendWin.obj : error LNK2001: unresolved external symbol "protected: virtual struct AFX_EVENTSINKMAP const * __thiscall CLegendWin::GetEventSinkMap(void)const " (?GetEventSinkMap@CLegendWin@@MBEPBUAFX_EVENTSINKMAP@@XZ)
在.h文件中申明了DECLARE_EVENTSINK_MAP()以后
在.pp文件里面就需要有以下部分的代码,不然就编译出错
BEGIN_EVENTSINK_MAP()
END_EVENTSINK_MAP()