How to block or set lock screen timeout using command prompt in Windows 10?
how to get out. If you forget to turn off your computer and care about the security of your data, then one of the possible ways to lock your PC is – “Command line” . You can use this method by following this instruction:
Locking the PC using the command line:
one. Press “Win + R” to open the window “Run” .
2. In the field “Open” enter “cmd”.
3. Enter this command "Rundll32.exe user32.dll, LockWorkStation"
.
Lock timeout setting:
1. In the search, type “cmd” and run as administrator by right-clicking.
2 . Run this command: “powercfg.exe /SETACVALUEINDEX SCHEME_CURRENT SUB_VIDEO VIDEOCONLOCK “.
3. Replace “” with time in seconds after which the PC will be blocked.
4. Type "powercfg.exe /SETACTIVE SCHEME_CURRENT"
.
Note: To set the laptop lock timeout, change the value of "/SETACVALUEINDEX"
to “/SETDCVALUEINDEX” and run the command as usual .