共用方式為


DEVPKEY_Device_PowerData

DEVPKEY_Device_PowerData裝置屬性代表裝置實例的電源資訊。

屬性

屬性索引鍵

DEVPKEY_Device_PowerData

Property-data-type 標識符

DEVPROP_TYPE_BINARY

屬性存取

安裝應用程式和安裝程式的唯讀存取權

對應SPDRP_Xxx標識符

SPDRP_DEVICE_POWER_DATA

當地語系化?

No

備註

Windows 會設定DEVPKEY_Device_PowerData的值。 DEVPKEY_Device_PowerData的值包含 CM_POWER_DATA 結構。

您可以呼叫 CM_Get_DevNode_PropertySetupDiGetDeviceProperty 來擷取DEVPKEY_Device_PowerData的值。

Windows Server 2003、Windows XP 和 Windows 2000 支援此屬性,但不支援DEVPKEY_Device_PowerData屬性索引鍵。 相反地,您可以使用對應的SPDRP_DEVICE_POWER_DATA標識符來存取這些舊版 Windows 上的 屬性值。 如需有關如何在這些舊版 Windows 上存取這個屬性值的資訊,請參閱 存取裝置實例SPDRP_Xxx屬性

需求

版本:Windows Vista 和更新版本的 Windows 標頭:D evpkey.h (包括 Devpkey.h)

另請參閱

CM_POWER_DATA

SetupDiGetDeviceProperty