c# code to put monitor to sleep and awake

Hi

I need a c# code solution to put a Windows 7 Pro monitor to sleep and wake up on command.

Thank you



What have you tried? What have you looked at?



What have you tried? What have you looked at?



No was to busy with other work. Was hoping maybe someone had some info.



Simple answer is:SendMessage(HWND_BROADCAST, WM_SYSCOMMAND, SC_MONITORPOWER, (LPARAM) 2);

Detail instructions are here:http://www.codeproject.com/Articles/12794/Complete-Guide-on-How-To-Turn-A-Monitor-On-Off-Sta



Thank you!



Share this

Related Posts

There was an error in this gadget