By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
425,534 Members | 1,830 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 425,534 IT Pros & Developers. It's quick & easy.

Delete files in folder based on modified date.

P: n/a
Let's say I have the following folder:
C:\Archive\Data\Logs\

and within this folder are many files in this format:
Cycle Run of Tuesday, February 01, 2005.html
Cycle Run of Wednesday, February 02, 2005.html
..
..
..
Cycle Run of Monday, February 28, 2005.html
The folder gets larger every day when a new file is created. What I
want to do is setup an application that would delete all the previous
month's files. I would setup an executable to run off a PC as a
'Scheduled Task' on the 28th of every month to delete the previous
month's files. So, example on the 28th of March it would delete all the
files that were created in February. I guess you would somehow use the
'Modified Date'?

Nov 21 '05 #1
Share this question for a faster answer!
Share on Google+

This discussion thread is closed

Replies have been disabled for this discussion.