(1)基本概念
Windows对系统版本的表示分为:主版本号、次版本号、构建号、sp主版本号、sp次版本号。
(2)相关API
BOOL GetVersionEx(
LPOSVERSION lpVersionInfo; //输入输出参数
)
OSVERSIONINFOEX 结构
typedef struct _OSVERSIONINFOEX {
DWORD dwOSVersionInfoSize;
DWORD dwMajorVersion;
DWORD dwMinorVersion;
DWORD dwBuildNumber;
DWORD dwPlatformId;
TCHAR szCSDVersion[128];
WORD wServicePackMajor;
WORD wServicePackMinor;
WORD wSuiteMask;
BYTE wProductType;
BYTE wReserved;
} OSVERSIONINFOEX, *POSVERSIONINFOEX, *LPOSVERSIONINFOEX;
(3)相关测试实例与
(1)基本概念
Windows对系统版本的表示分为:主版本号、次版本号、构建号、sp主版本号、sp次版本号。
(2)相关API
BOOL GetVersionEx(
LPOSVERSION lpVersionInfo; //输入输出参数
)
OSVERSIONINFOEX 结构
typedef struct _OSVERSIONINFOEX {
DWORD dwOSVersionInfoSize;
DWORD dwMajorVersion;
DWORD dwMinorVersion;
DWORD dwBuildNumber;
DWORD dwPlatformId;
TCHAR szCSDVersion[128];
WORD wServicePackMajor;
WORD wServicePackMinor;
WORD wSuiteMask;
BYTE wProductType;
BYTE wReserved;
} OSVERSIONINFOEX, *POSVERSIONINFOEX, *LPOSVERSIONINFOEX;
(3)相关测试实例与