Search This Blog

Wednesday, October 27, 2010

Lock your machine through the script

Add the below code to end of script to lock the machine automatically

Set obj = CreateObject("WScript.Shell")
sCmnd = "%windir%\SYSTEM32\rundll32.exe user32.dll,LockWorkStation"
obj.Run sCmnd, 0, False
Set obj =nothing

No comments:

Post a Comment