mystics7
asked on
VBS to delete file time in folder and sub folders
I'm looking to have a scheduled task that runs a VBS script (called from a bat file) that deletes PDF Files is a folder and it's sub folders. Thank you in advance for your help!!!!!
ASKER
this will also delete the pdfs from the sub folders?
ASKER
I also forgot to mention that this has to be done one files older than 30 days
Why not just use this handy little free utility called DELAGE32
http://home.mnet-online.de/horst.muc/win/delage.htm
http://home.mnet-online.de/horst.muc/wbat32.htm
So a simple command like the following could do it for you:
delage32 c:\temp\*.pdf 31 /recurse
~bp
http://home.mnet-online.de/horst.muc/win/delage.htm
http://home.mnet-online.de/horst.muc/wbat32.htm
So a simple command like the following could do it for you:
delage32 c:\temp\*.pdf 31 /recurse
~bp
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
DEL C:\your_folder\*.pdf /S /Q /F