vc6编译wtl71 的例子出错,如下
c:/wtl71/include/atlframe.h(274) : error C2501: 'LPNMREBARCHEVRON' : missing storage-class or type specifiers
c:/wtl71/include/atlframe.h(905) : see reference to class template instantiation 'WTL::CFrameWindowImplBase <TBase,TWinTraits>' being compiled
c:/wtl71/include/atlframe.h(274) : error C2501: 'lpnm' : missing storage-class or type specifiers
c:/wtl71/include/atlframe.h(905) : see reference to class template instantiation 'WTL::CFrameWindowImplBase <TBase,TWinTraits>' being compiled
.......
解决:
在stdatl.h里 注释掉下面三行,不然 vc6不能编译
/* #define WINVER 0x0500
#define _WIN32_WINNT 0x0500
#define _WIN32_IE 0x0501
*/
或者使用vs2003或以上编译即可
本文介绍了在使用VC6编译WTLC71示例时遇到的错误,并提供了两种解决方案:一是通过注释掉stdatl.h文件中特定的预处理器指令;二是推荐使用VS2003或更高版本进行编译。
526





