title: .NET - setting power options from code
body: <p>I'd like to write very simple code from C# - a simple 2 button app that will allow me to change the action that is taken when the lid is closed.
  From "sleep" to "no action" and vice versa.</p>
  
  <p>I found that it somehow connected to WMI - but no actual info on how achieving this.</p>
  
  <p>help would be much appreciated.</p>
  
  <p>Thanks!</p>