0

I've been using the autologin-and-lock solution as described in "Automatically login and lock" since Windows 7. Because I had a Pro license I used the gpedit variant, and found that the autologin was instantaneously followed by locking the screen such that the desktop wasn't even visible before the lock screen returned. However, I've found that on Windows 8.1 and Windows 10, the screen does not instantaneously lock, it instead idles on the desktop for 10-20 seconds before locking.

Is there a reason for this delay and/or can it be reduced/fixed?

fjord
  • 1

1 Answers1

0

Best way is to run the following command as a Scheduled Task, setting the Trigger to "at logon"

rundll32.exe user32.dll,LockWorkStation

When creating a task, make sure you type C:\Windows\system32\rundll32.exe in the Program name field. And user32.dll,LockWorkStation in the parameter field.

Scheduled Task (triggered at logon) kicks in immediately after login.. and much earlier than the items mentioned in registry Run keys or Startup folder execute.

See also. How to Setup Automatic Login and Auto-Lock Workstation After Login?

w32sh
  • 11,889