PowerSource Enumeration
Collapse the table of content
Expand the table of content

PowerSource Enumeration

[ This article is for Windows Phone 8 developers. If you’re developing for Windows 10, see the latest documentation. ]

Indicates whether the device is currently running on battery power or is plugged in to an external power supply.

Namespace:  Microsoft.Phone.Info
Assembly:  Microsoft.Phone (in Microsoft.Phone.dll)

public enum PowerSource
<object property="enumerationValue" .../>

Member nameDescription
BatteryThe device is running on battery power.
ExternalThe device is plugged in to an external power source, such as being docked to a computer or connected to a power supply.

In addition to accessing this property directly, you can register for the PowerSourceChanged event handler to be notified when the power source of the device has changed.

Windows Phone OS

Supported in: 8.1, 8.0, 7.1

Windows Phone

Show:
© 2017 Microsoft