Download Active Perl (for NT) from perl.com and write a simple script.

Here is a sample script I use. I learned a little bit of Perl just for this script purposes so this may not be the best script --


opendir(dirname, "d:/archive2/");

$count = 0;
$age = 0;

#---------------------------------------------------------------------
# Read one file at a time and delete if it is older than specified days
#---------------------------------------------------------------------

while ($file = readdir(dirname))
{
#-------------------------------------------------------------
# Prefix the file name with the directory Path otherwise
# it will not delete
#-------------------------------------------------------------

$file = "d:/archive2/" . $file;
$age = -M $file;
print "$file is $age days old\n";

#-------------------------------------------------------------
# Check if the file is at least 7 days old
#-------------------------------------------------------------

if ($age > 7)
{
#-----------------------------------------------------
# Delete the file
#-----------------------------------------------------
unlink($file);
print "Deleted file : $file\n";
$count = $count +1;
}
}
closedir dirname;
print "Total $count files were deleted. \n";