Thursday, January 22, 2009

Locking PC after execution of Automation scripts

You can use the following QTP Script to lock your PC :

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

No comments: