Protect your Folder with a Password in Window 7. You can also hide your Folder using this trick. You don't have to use any software to protect your folder. Just follow the instructions as given below:
Step 1: Open notepad (Start> Run> Type "notepad" and Enter
Code:
Step 3: Replace "pccompnet" written in yellow color in the above code with your password.
Step 4: Save that notepad with any name and Change the extension from ".txt" to ".bat"
Step 1: Open notepad (Start> Run> Type "notepad" and Enter
or Right Click and Select "Text Document"
Step 2: Copy Paste the Code given below in that notepad.
cls
@ECHO OFF
title sunny Folder Locker
if EXIST
"RecycleBin.{645ff040-5081-101b-9f08-00aa002f954e}" goto UNLOCK
if NOT EXIST Locker goto sunny
:CONFIRM
echo Are you sure to Lock this 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
if %cho%==k goto sunny
if %cho%==K goto sunny
echo Invalid choice.
goto CONFIRM
:LOCK
ren Locker
"RecycleBin.{645ff040-5081-101b-9f08-00aa002f954e}"
attrib +h +s
"RecycleBin.{645ff040-5081-101b-9f08-00aa002f954e}"
echo Folder locked
goto End
:UNLOCK
echo Enter password to Unlock Your Secure Folder
set/p "pass=>"
if %pass%==k goto K2H
if %pass%==K goto K2H
if NOT %pass%== pccompnet goto
FAIL
attrib -h -s
"RecycleBin.{645ff040-5081-101b-9f08-00aa002f954e}"
ren "RecycleBin.{645ff040-5081-101b-9f08-00aa002f954e}"
Locker
echo Folder Unlocked successfully
goto End
:FAIL
echo Invalid password
goto end
:sunny
md Locker
echo Locker created successfully
goto End
:sunny
start iexplore.exe
:End
|
Step 3: Replace "pccompnet" written in yellow color in the above code with your password.
Step 4: Save that notepad with any name and Change the extension from ".txt" to ".bat"
- If you are not able to see the extension, then you have to unhide your extension.
- To unhide extension, Click on "Organize" from top left and select "Folder and Search Option"
- Click on "View" Tab and unclick "Hide extensions from known file types" and Save.
Step 5: Now you ca be able to see the extension as "new text document.txt". Just rename that as "anything.bat".
Step 6:
- Double Click on "anything.bat", a new Folder with name "Locker" will automatically be created.
- This "Locker" Folder is your secret folder. Just move or save anything in that folder that you want to lock or hide with a password.
- Moved...? Now you are ready to lock your folder.
Step 7:
You can also see my Video for the same here:
- Again double click on "anything.bat" file, a command prompt will appear, just press "Y" to hide that folder.
- You will see that, the "Locker" folder has disappeared or hidden.
- To unhide that folder again, again just double click on "anything.bat" file, and in Command Prompt, just enter your password (which you have saved earlier).
- Done, you can now see that folder again.
If you want to completely hide a Folder for free, then my post on hide a folder.
You can also see my Video for the same here:
Thanx buddy its most easiest and free way to hide stuff
ReplyDeletekeep and you are the great
Allah hafiz
thanks for liking it..!
Deletevery useful indeed, only drawback for me is the fact the password is visible when you unlock the folder.
ReplyDeletemaybe a little adjustment is needed to asterix out the password or maybe even make it linux when you nothing being typed
yaa you are right, but only the owner will be able to unlock the folder, so their is no risk even if it is visible after unlocking it.
DeleteIf you want you can covert .bat file into .exe file so that no one will be able to edit (more secure).
But it will be good to keep it simple only, rather than making it complicated, as we are only hiding our personal documents.
thanks for suggesting it...!
Gaurav KushwahaJuly 28, 2014 at 7:12 PM
DeleteThat is not correct. Anyone can open the folder that holds the bat file. All they have to do is drop the bat file on a notepad icon and the entire script with password becomes visible.
What will happen if the file "anything.bat" will be deleted unexpectedly? Any recovery method to get the files which were hidden into the Locker Folder?
ReplyDeleteCouldn't you just recreate "anything.bat"?
Deletenice man you answered on what i need to do. thanks man.......
ReplyDeleteThis information you provided in the blog that is really unique I love it!! Thanks for sharing such a great blog Keep posting..
ReplyDeleteHow to Lock Google Chrome with Password