How do I encrypt a win8.1/win10 folder?
Method/Step
Small series on the name of their own folder to do the demonstration
First, create a new text document
Enter the following exactly when opened
Cls
@ECHO off
Title Folder Private
If EXIST "HTG Lock" goto UNLOCK
If not EXIST Private goto Mdlock
: CONFIRM
Echo, are you sure you want to encrypt the hidden private 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 "HTG Lock"
attrib +h +s "HTG Lock"
Echo Folder Locked
Goto END
: UNLOCK
Echo enters a password to unlock the folder
set/p "Pass=>"
If not%pass%== this setting password goto FAIL
Attrib-h-S "HTG Lock"
ren "HTG Lock" Private
Echo Folder Unlocked successfully
Goto END
: FAIL
echo Invalid Password
Goto END
: Mdlock
MD Private
Echo Private created successfully
Goto END
: End
"Set password Here" can be replaced by the password you want to set, pay attention to do not delete the space, when finished remember to save
Let's rename the file you just edited and rename it to Lock.bat.