kbay808
asked on
How to create a batch or vbs file to delete all the system files in a folder?
I'm trying to create a script that will delete all of the files in the below folder.
C:\Users\[Current User]\AppData\LocalLow\Mic rosoft\Cry ptnetUrlCa che\Conten t
I tried this with no success.
del /f /q "%userprofile%\AppData\Loc alLow\Micr osoft\Cryp tnetUrlCac he\Content \*."
C:\Users\[Current User]\AppData\LocalLow\Mic
I tried this with no success.
del /f /q "%userprofile%\AppData\Loc
ASKER
I tried that, but it did not work for system files. Please see the attached screen shot.
Screen-Shot.JPG
Screen-Shot.JPG
You may need to run this with elevated administrator privileges.
~bp
~bp
ASKER
I tried to run it as an administrator, but no joy. I even tried it on a test file on my desktop and still no joy. I attached a copy of the test file.
@echo off
del /f /q "%userprofile%\Desktop\Test Delete\*."
Test-Delete.zip
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Thanks!!! That worked great!!!
del /f /q "%userprofile%\AppData\Loc
~bp