run regedit
HKEY_LOCAL_MACHINE > SOFTWARE > Policies > Microsoft > Windows
Right pane: New > Key
Name the key: Personalization
Click the new Personalization key
Right pane: right click > New > DWORD 32bit
Name it: NoLockScreen
Double click NoLockScreen and set value as: 1
Close the Registry Editor and Restart the computer