UID | title | description | helpviewer_keywords | old-location | tech.root | ms.assetid | ms.date | ms.keywords | req.header | req.include-header | req.target-type | req.target-min-winverclnt | req.target-min-winversvr | req.kmdf-ver | req.umdf-ver | req.ddi-compliance | req.unicode-ansi | req.idl | req.max-support | req.namespace | req.assembly | req.type-library | req.lib | req.dll | req.irql | targetos | req.typenames | req.redist | ms.custom | f1_keywords | dev_langs | topic_type | api_type | api_location | api_name | ||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
NF:powrprof.PowerDeterminePlatformRole |
PowerDeterminePlatformRole function (powrprof.h) |
Determines the computer role for Windows 7, Windows Server 2008 R2, Windows Vista or Windows Server 2008. |
|
base\powerdetermineplatformrole.htm |
base |
a0311454-3908-49a6-95c0-c118dca259ac |
12/05/2018 |
PowerDeterminePlatformRole, PowerDeterminePlatformRole function, base.powerdetermineplatformrole, powrprof/PowerDeterminePlatformRole |
powrprof.h |
Windows |
Windows Vista [desktop apps only] |
Windows Server 2008 [desktop apps only] |
PowrProf.lib |
PowrProf.dll |
Windows |
19H1 |
|
|
|
|
|
|
Determines the computer role for Windows 7, Windows Server 2008 R2, Windows Vista or Windows Server 2008. To specify a different platform, use the PowerDeterminePlatformRoleEx function.
To query additional power platform roles defined after Windows 7 and Windows Server 2008 R2, use PowerDeterminePlatformRoleEx.
The return value is one of the values from the POWER_PLATFORM_ROLE enumeration.
This function reads the ACPI Fixed ACPI Description Table (FADT) to determine the OEM preferred computer role. If that information is not available, the function looks for a battery. If at least one battery is available, the function returns PlatformRoleMobile. If no batteries are available, the function returns PlatformRoleDesktop.
Note This API has a newer version. To query additional power platform roles defined after Windows 7 and Windows Server 2008 R2, use PowerDeterminePlatformRoleEx.