VB.NET has an event that fires when a computer's power mode is changed (SystemEvents.PowerModeChanged).
I need my program to find out what caused the power mode change, specifically, if there was a power button pressed, or some other reason.
How can I program this in VB.NET?