Unblock files in folder
Windows adds a security
block to files downloaded from the Internet, which can prevent users from running or editing the files.
The following script can search recursively through all files and folders in the folder specified by $FolderPath
and removing the security block on all files found.
info
Before running the script please fill out the variables
$FolderPath
: Insert the root folder for the folders you wish to unblock all files in.
Be aware that the function is running recursive and therefor also unblocks all files in subfolders.
$FolderPath = '';
Get-ChildItem -Path $FolderPath -Recurse | Unblock-File;