Lock Machine (Computer) using VB Script
My good friend Venugopala Reddy Ragi had a good VBScript snippet to lock computer. Probably useful for someone to enhance security
Set WshShell = WScript.CreateObject("WScript.Shell")
WshShell.Run "rundll32 user32.dll,LockWorkStation"
Thursday, August 21, 2008
Download Windows Live Toolbar and personalize your Web experience! Add custom buttons to get the information you care about most.
its damn pretty!!
ReplyDeleteYeah real cute. But how do you unlock the computer?
ReplyDeleteThen how to Unlock Computer when VB script working on it.....?
ReplyDeleteSincerely Waiting for your Reply..
I think you just restart the computer and the script shuts down therefor unlocking it?
ReplyDeleteAll this script does is take you to the logout screen. It's no different that pressing winkey+l, or (assuming you're running XP) by clicking the logoff button in the Start Menu, and selecting "Switch User". All you do to get back into Windows is log on just like you would if the computer was starting up.
ReplyDeleteAlso, you can take the last bit, "rundll32 user32.dll,LockWorkStation" (without quotes), and type it into a command prompt or batch script and get the same result.
Either way, this could come in quite handy if you want Windows to start up your profile automatically (perhaps so you can walk away while your startup apps are loading), but don't want people to mess with your computer. At lest that's what I will use it for :)