I need to detect the system power state mode. To be precise, I need an event which fires up when windows 7 wakes up from sleep. I am already using:
SystemEve
SystemEvents.PowerModeChanged += OnPowerModeChange; private void OnPoweModerChange(object s, PowerModeChangedEventArgs e) { if(e.Mode==PowerModes.Suspend) { //Apply your operation } }
Use this code to do your job