Run script on wake

Would it be possible to detect when a computer wakes up from sleep, and then execute some code?

Hi,

look at Registering and unregistering for sleep and wake notifications

thanks. got it working perfectly

Hello

There is a utility called sleepwatcher, which you can find which can be found by google.
It is quite easy to use and install.

Best Regards

McUsr

Unless you’re doing something custom, sleepwatcher, which has been updated for 10.6 is king for launching scripts or performing actions. On macupdate