IDebugControl4::GetSystemVersionValues 方法 (dbgeng.h)

GetSystemVersionValues 方法返回当前目标的版本号信息。

语法

HRESULT GetSystemVersionValues(
  [out]           PULONG PlatformId,
  [out]           PULONG Win32Major,
  [out]           PULONG Win32Minor,
  [out, optional] PULONG KdMajor,
  [out, optional] PULONG KdMinor
);

参数

[out] PlatformId

接收平台 ID。 对于基于 NT 的 Windows,PlatformId 始终VER_PLATFORM_WIN32_NT。

[out] Win32Major

接收目标操作系统的主版本号。 对于 Windows 2000、Windows XP 和 Windows Server 2003,此数字为 5。 对于 Windows Vista、Windows 7 和 Windows 8,此数字为 6。

[out] Win32Minor

接收目标操作系统的次要版本号。 对于 Windows 2000,此值为 0;对于 Windows XP,为 1;适用于 Windows Server 2003、2. 对于 Windows Vista,此值为 0;适用于 Windows 7、1;Windows 8,2.

[out, optional] KdMajor

如果目标操作系统是免费版本,则接收0xF,如果它是已检查的内部版本,则接收0xC。

[out, optional] KdMinor

接收目标操作系统的内部版本号。

返回值

此方法也可能返回错误值。 有关更多详细信息 ,请参阅返回值

返回代码 说明
S_OK
方法成功。

注解

有关详细信息,请参阅 目标信息

要求

要求
目标平台 桌面
标头 dbgeng.h (包括 Dbgeng.h)

另请参阅

GetSystemVersion

GetSystemVersionString

IDebugControl4