OSVERSIONINFOEX

[This is preliminary documentation and subject to change.]

The OSVERSIONINFOEX structure contains operating system version information. The information includes major and minor version numbers, a build number, a platform identifier, and information about the latest Service Pack installed on the system. This structure is used with the GetVersionEx function. OSVERSIONINFOEX is an extended version of the OSVERSIONINFO structure.

typedef struct _OSVERSIONINFOEXA {
    DWORD dwOSVersionInfoSize;
    DWORD dwMajorVersion;
    DWORD dwMinorVersion;
    DWORD dwBuildNumber;
    DWORD dwPlatformId;
    TCHAR szCSDVersion[ 128 ];
    WORD wServicePackMajor;
    WORD wServicePackMinor;
    WORD wReserved[2];
} OSVERSIONINFOEXA, *POSVERSIONINFOEXA, *LPOSVERSIONINFOEXA;
 

Members

dwOSVersionInfoSize
Specifies the size, in bytes, of this data structure. Set this member to sizeof(OSVERSIONINFOEX) before calling the GetVersionEx function.
dwMajorVersion
Identifies the major version number of the operating system. For example, for Windows NT version 5.0, the major version number is 5.
dwMinorVersion
Identifies the minor version number of the operating system. For example, for Windows NT version 5.0, the minor version number is 0.
dwBuildNumber
Identifies the build number of the operating system.
dwPlatformId
Identifies the operating system platform. This member can be one of the following values.
Value Platform
VER_PLATFORM_WIN32s Win32s on Windows 3.1.
VER_PLATFORM_WIN32_WINDOWS Win32 on Windows 95 or Windows 98.
VER_PLATFORM_WIN32_NT Win32 on Windows NT.

szCSDVersion
Contains a null-terminated string, such as "Service Pack 3", that indicates the latest Service Pack installed on the system. If no Service Pack has been installed, the string is empty.
wServicePackMajor
Identifies the major version number of the latest Service Pack installed on the system. If no Service Pack has been installed, the value is zero.
wServicePackMinor
Identifies the minor version number of the latest Service Pack installed on the system. If no Service Pack has been installed, the value is zero.
wReserved
Reserved for future use.

QuickInfo

  Windows NT: Requires version 5.0 or later.
  Windows: Unsupported.
  Windows CE: Unsupported.
  Header: Declared in winbase.h.
  Unicode: Defined as Unicode and ANSI structures.

See Also

System Information Overview, System Information Structures, GetVersionEx, OSVERSIONINFO