检索指定电源设置的 DC 值索引。
语法
DWORD PowerReadDCValueIndex(
[in, optional] HKEY RootPowerKey,
[in, optional] const GUID *SchemeGuid,
[in, optional] const GUID *SubGroupOfPowerSettingsGuid,
[in, optional] const GUID *PowerSettingGuid,
[out] LPDWORD DcValueIndex
);
参数
[in, optional] RootPowerKey
此参数保留供将来使用,必须设置为 NULL。
[in, optional] SchemeGuid
电源方案的标识符。
[in, optional] SubGroupOfPowerSettingsGuid
电源设置子组的标识符。 使用 NO_SUBGROUP_GUID 引用默认电源方案。
这些值是 Windows 附带的子组值。
[in, optional] PowerSettingGuid
电源设置的标识符。
[out] DcValueIndex
指向接收 DC 值索引的变量的指针。
返回值
如果调用成功,则返回 ERROR_SUCCESS (零) ;如果调用失败,则返回非零值。
要求
| 要求 | 值 |
|---|---|
| 最低受支持的客户端 | Windows Vista [仅限桌面应用] |
| 最低受支持的服务器 | Windows Server 2008 [仅限桌面应用] |
| 目标平台 | Windows |
| 标头 | powrprof.h |
| Library | PowrProf.lib |
| DLL | PowrProf.dll |