- Joined
- Mar 28, 2011
- Sythe Gold
- 8
- Messages
- 1,791
How to lock folders on your PC
Why would you want to lock folders on your PC?
I like to use this method to hide passwords and folders that I'm not supposed to have on my school computer. By using this method and using the "hide folder" feature, your parents or teachers will not find your hidden documents. I like using this method because it also works on USB's and doesn't require a program. After reading this guide you can have your password folder set up in seconds.
What do i need to do?
Open up a blank Notepad and copy and paste this code:
cls
@ECHO OFF
title Folder Personal
if EXIST "Control Panel.{21EC2020-3AEA-1069-A2DD-08002B30309D}" goto UNLOCK
if NOT EXIST Personal goto MDLOCKER
:CONFIRM
echo Are you sure u want to lock the folder(Y/N)
set/p "cho=>"
if %cho%==Y goto LOCK
if %cho%==y goto LOCK
if %cho%==n goto END
if %cho%==N goto END
echo Invalid choice.
goto CONFIRM
:LOCK
ren Personal "Control Panel.{21EC2020-3AEA-1069-A2DD-08002B30309D}"
attrib +h +s "Control Panel.{21EC2020-3AEA-1069-A2DD-08002B30309D}"
echo Folder locked
goto End
:UNLOCK
echo Enter password to Unlock folder
set /p "pass=>"
if NOT %pass%==password goto FAIL
attrib -h -s "Control Panel.{21EC2020-3AEA-1069-A2DD-08002B30309D}"
ren "Control Panel.{21EC2020-3AEA-1069-A2DD-08002B30309D}" Personal
echo Folder unlocked successfully
goto End
:FAIL
echo Invalid password
goto UNLOCK2
:FAIL2
echo Invalid password
goto end
:MDLOCKER
md Personal
echo Folder created successfully
goto End
:UNLOCK2
echo Last chance to enter correct password to unlock folder
set /p "pass=>"
if not %pass%==password goto FAIL2
attrib -h -s "Control Panel.{21EC2020-3AEA-1069-A2DD-08002B30309D}"
ren "Control Panel.{21EC2020-3AEA-1069-A2DD-08002B30309D}" Personal
echo Folder unlocked successfully
:End
To edit the name of your hidden folder, alternate every "Personal" with whatever name you choose. For this example i'll be naming my folder "Screenshots"
To edit the password of your hidden folder, alternate the bold "password" with the password of your choice.
For this guide i'll be using "blazee" as my password.
After editing the code to your liking, go to File>Save As and save it as locker.bat as shown.
After saving it you should have a locker.bat file in your folder. Double click it and this should open up. Type in your password and hit enter.
Your "Personal" should now appear and you are now able to drag your secret documents into there. When your done, simply double click on the locker.bat and type "Y" to lock the folder.
What else can I do to make sure no-body finds this locker.bat file?
"Hiding" the folder will make the locker.bat file invisible if you have "Do not show hidden folders and files" ticked. To hide the .bat file, right click it and go to Properties>General and make sure the hidden box is ticked. The locker.bat should now be a transparent folder.
To make sure "Do not show hidden folders and files" is ticked, go to Organize>Folders and search options
To find the hidden locker again go back into Organize>Folders and search options and tick "Show hidden files and folders"

















