I am the only user of my laptop and the only reason i use a password is to prevent theft.

the quirk that i have with logon passwords is that the startup items will only load after i have keyed in the password.

is it possible to get win8 pro x64 to load all the startup items while it is still at the logon screen, so that it is ready for use immediately after i key in the password?



Use autologon to autologon your account. Now create a scheduled task which runs at logon (configure the trigger correctly) and locks the PC with the command:

rundll32.exe User32.dll,LockWorkStation

Rundll32.exe is the program you select and add the other 2 values to parameter.

When you now start the PC, Windows runs all startup tools but locks the PC and you have to enter the password. After you entered the password, Windows has all tools started for you.

| improve this answer | |
  • 1
    Interesting workaround. Does this immediately lock the PC on startup? Or does it have to wait till all the applications are loaded? – Keltari May 2 '13 at 6:23
  • 1
    Windows runs scheduled tasks with a lower priority, so there maybe a small gap before the locks screen occur, but the tools should start fine in background. – magicandre1981 May 2 '13 at 17:16
  • 1
    well, I +1'd it. Its a working answer to the OPs issue and it meets the requirements. However, I think its a small security risk. But the reality is, nothing is gained. If he logs on and waits for his programs to start it will take X number of seconds. If he applies your answer, the same number of seconds elapse, he just might not be sitting there waiting for it while booting. Nitpicking, but my 2 cents. – Keltari May 2 '13 at 23:06
  • sorry for the newbie question - but how do i add a scheduled task that can allow command input? or do i just create a .bat with the command you just mentioned, and throw it into the startup folder of win8? – Automator_Junkie May 3 '13 at 3:08
  • what do you mean with input? Here are the steps to create the task: techdows.com/2012/11/manage-schedule-tasks-windows-8.html – magicandre1981 May 3 '13 at 3:59

I managed to lock the PC immediately on startup while loading windows/startup items in the background. This works with Windows editions that has group policy editor.

Step 1: Open notepad, then paste this code:

WScript.CreateObject("WScript.Shell").Run("rundll32 user32.dll,LockWorkStation")

Step 2: Click File>Save As and in Save as type dropdown menu, choose All Files

Step 3: In the File Name field, enter LockWorkStation.vbs and save the file to C:\Users\YourUserName\Documents

Step 4: Hit WindowsKey+R, type regedit and press ENTER

Step 5: Go to HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System

Step 6: Right Click on a blank space and click New> DWORD (32-bit) Value and press ENTER

Step 7: Double click the newly created REG_DWORD file. In the Value name type RunLogonScriptSync and in the Value data type1 and then press ENTER

Step 8: Hit WindowsKey+R, type gpedit.msc and press ENTER

Step 9: Under Computer Configuration, go to Administrative Templates > System > Logon then Double Click Run these programs at user logon

Step 10: Click Enabled, and on Items to run at logon click Show...

Step 11: Type C:\Users\YourUserName\Documents\LockWorkStation.vbs and click OK repeatedly until all windows are closed

Step 12: Hit WindowsKey+R and type control.exe userpasswords2 then press ENTER

Step 13: Uncheck Users must enter a user name and password to use this computer. then click OK (type in your password if it prompts to do so)

Step : Restart your PC.

Now whenever you start your PC, the .vbs script will run first before anything else. This will ensure that your PC is locked before the desktop appears.

Note: You can change C:\Users\YourUserName\Documents\ to wherever you want to store your script.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.