Skip to content Skip to sidebar Skip to footer

How to give a password to a file using Windows In Notepad

How to give a password to a file using Windows In Notepad

Giving Password Files Using Windows Notepad - in this post, admin pansoserz will give a simple trick, namely How to Give Password Files Using Windows Default Notepad.

Previously, the admin has made an article about How to Give Passwords in Compressed Files, now in this article, we will only lock files using Notepad, sounds very strange, right? Yes, because people rarely lock files using Notepad, even though we can use Notepad to lock files.

Before going to the tutorial, it would be nice to first know the history of Notepad, Notepad is a text editor that was created on Windows around 1985, here I will give a little use of Notepad.

Uses of Notepad

  • To Remove Links IN Text
  • To Make Short Writing (Not SMS)
  • To Edit HTML Or make HTML

Well, now you know right? The history of Notepad and its uses, now we live to discuss the tutorial, continued.

How to Provide File Password Using Notepad 

1. First, we have to create a folder first, how you can right-click the mouse> click New > click Folder > fill in the folder name with the example Locked.

2. If you have, you open Notepad by clicking the Windows icon on the keyboard + R > fill in Notepad or you can also click the windows icon in the bar > then click All Programs > Accessories > Notepad.

3. If you have opened the notepad, you copy the code below and paste it into the notepad

cls
@ECHO OFF
title Folder Private
if EXIST "Control Panel.{21EC2020-3AEA-1069-A2DD-08002B30309D}" goto UNLOCK
if NOT EXIST Private goto MDLOCKER
:CONFIRM
echo Are you sure you 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 Private "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 gayn goto FAIL
attrib -h -s "Control Panel.{21EC2020-3AEA-1069-A2DD-08002B30309D}"
ren "Control Panel.{21EC2020-3AEA-1069-A2DD-08002B30309D}" Private
echo Folder Unlocked successfully
goto End
:FAIL
echo Invalid password
goto end
:MDLOCKER
md Private
echo Private created successfully
goto End
:End

4. If you have pasted the code, you look for the text.  You change the text called password gayn to the password you want, for example, pansoserz123. if NOT %pass%== password gayn goto FAIL

5. If you have, you save As the file with the name Locked.bat and save it in the folder that we created earlier.

6. Next, we open the Locked Folder that we created earlier, the Locked.bat folder will appear earlier, please double click (click x2) the file, a file named private will appear, now that's where you can save the file/photo that you want to hide.

7. Then, you double-click the Locked.bat file again, it will display the text "  Are you sure you want to lock the folder ", you type " Y " to lock the file, click " N " to cancel locking the file.

8. If you have, try clicking on the .bat-formatted file earlier, it will look like asking for a password, and if you type the password correctly, the private file will appear.

Well, that's it, friends, about the article How to Give Password Files Using Windows Default Notepad, hopefully useful, and don't forget to share the article with your friends, thank you for visiting.

Farhan.
Farhan. Beginner Writer.