Thursday, May 5, 2011

Code for avoiding lock/Screensaver.

Set WshShell = WScript.CreateObject("WScript.Shell")
count= 1
For i= 0 To 60
WshShell.SendKeys "{F6}"
Wscript.Sleep 180000
count = count+1
Next

This will keep hitting F6 Key periodically to avoid system from sleeping/locking

No comments:

Post a Comment