Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

C#, wake computer from sleep

Name: Anonymous 2011-01-24 12:51

I'm creating a small alarm clock for fun, and I want to wake up the computer from sleep at a certain time.

I found this code, http://www.pcreview.co.uk/forums/showpost.php?p=11849260&postcount=4, and it works.
But.. as soon as I initiate it the program becomes unresponsive until the timer is finished.

What to do?

Name: Anonymous 2011-01-24 13:57

>>6
The point is P/Invoke has nothing to do with running code while the system is asleep. It's just (apparently, but I'm doubtful) the only way to setup a handler for the alarm, in this case by using kernel32.dll calls.

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List