Simple C# System battery information library
Create new instance of BatteryInfo.Battery class and call Update().
BatteryInfo.Battery battery = new BatteryInfo.Battery();
battery.Update();
Console.WriteLine("Charge: \t" + battery.ChargePercent + " %");
BatteryInfo uses WML queries to get required data. WML may be unavailable on other operating systems than Windows.