解决办法如下:
#define WINVER 0x0600
做如上定义表示指定你的app所能运行的最低版本操作系统为Windows Vista,而不是你建立该工程的操作系统(即开发该app操作系统)
It defaulted to 0x0501 because you build on XP but defining it as 0x0400 will allow it to run on Windows 2000 as well.
Windows NT 4.0 use 0x0400
Windows 2000 use 0x0500
Windows XP use 0x0501
Windows Vista use 0x0600
在工程StdAfx.h 文件开始时写入:
#ifndef WINVER
#define WINVER 0x0500
#endif
// Specifies that the minimum required platform is Windows XP.
本文详细介绍了如何通过在应用程序的头文件中定义WINVER宏来解决Windows应用程序与不同版本操作系统的兼容性问题,包括从Windows NT 4.0到Windows Vista的版本兼容性调整。
2329

被折叠的 条评论
为什么被折叠?



