Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Keyboard/Mouse Locking/Disabling?

Status
Not open for further replies.

Troy28M

Programmer
Jan 24, 2005
24
US
Is it possible to disable/lock the keyboard/mouse with vbscript? I have a client-side script that compares files from a server with the client's files and replaces/adds if necessary. I would like to disable the possibility of conflict by taking the mouse and keyboard inputs away from the user during the update. Once update has completed, enable again.

3rd party software is not a possibility, so my question pertains to systems running OS - XP Professional.
 
You could cause the user's workstation to lock, but it wouldn't stop the user from unlocking the machine. If your script runs fast, that may give you enough time to do your compare and copy.

Code:
objShell.Run "%systemroot%\System32\rundll32.exe user32.dll,LockWorkStation", , False


PSC

Governments and corporations need people like you and me. We are samurai. The keyboard cowboys. And all those other people out there who have no idea what's going on are the cattle. Mooo! --Mr. The Plague, from the movie "Hackers
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top