A reader asks if it’s possible to automatically login to Windows and then lock the workstation immediately. Here is a legitimate case where it’s required.
"The IT department has begun pushing out periodic Automated Updates overnight which subsequently reboot my workstation. The negative result of this process is my scheduled tasks, which require my network credentials, fail because I am no longer logged into the network when the task is scheduled to run. I leave my workstation logged in and locked (for security) when unattended."
First, you must setup automatic logon to your user account. Secondly, place a script in the Startup folder that’ll lock the workstation after logging on. Microsoft MVP Mitch Tulloch’s Tip Locking a desktop at logon tells you how to lock the workstation after logging on, using the following command:
Whereas in Windows Vista (and Windows XP), you can place a shortcut to tsdiscon.exe in the Startup folder, and have it lock the workstation for you at startup. The common Startup folder is located here:
In Windows XP
In Windows Vista
Related Posts
- Add “Lock Workstation” Command to the Windows XP Start Menu
- Add Enhanced Shutdown Button to the Windows XP Start Menu
- Why Is There a Lock (Padlock) Icon on Some Files and Folders in Windows 7?
- How to Change User Account Password at Command Prompt
- Virtual PC 2007 Security Options: Restrictions for Limited Users
If you enjoyed this post, make sure you subscribe to our RSS feed! We feature Tips, Troubleshooting information, Scripts and Utilities for Microsoft Windows Operating Systems!
Prefer an E-mail subscription?




