Share via


BatteryStatus enumeration

[This documentation is preliminary and is subject to change.]

Indicates the status of the battery.

Syntax

var value = Windows.System.BatteryStatus.notPresent;
public enum BatteryStatus
Public Enum BatteryStatus
public enum class BatteryStatus

Attributes

[Version]

Members

The BatteryStatus enumeration has these members.

Member Value Description
NotPresent | notPresent 0

The battery or battery controller is not present.

Discharging | discharging 1

The battery is discharging.

Idle | idle 2

The battery is idle.

Charging | charging 3

The battery is charging.

Remarks

This enumerations is used as part of the BatteryReport class to provide information about a Battery object.

If the battery controller is removed after you create a Battery object, the Status will be NotPresent.

Requirements (device family)

Device family

Universal

API contract

Windows.Foundation.UniversalApiContract, introduced version 1.0

Namespace

Windows.System Windows::System [C++]

Metadata

Windows.Foundation.UniversalApiContract.winmd