Skip to content

Instantly share code, notes, and snippets.

@dck-jp
Created September 18, 2012 10:17
Show Gist options
  • Save dck-jp/3742437 to your computer and use it in GitHub Desktop.
Save dck-jp/3742437 to your computer and use it in GitHub Desktop.
Set Windows To Sleep Mode
using System.Windows.Forms;
namespace SetSuspend
{
class Program
{
static void Main(string[] args)
{
Application.SetSuspendState(PowerState.Suspend, false, false);
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment