Here is a script I wrote to kill files whose modification date is 11 days old. The only way I found to do that to a number of files was to check each file, one at a time. The script does what I want it to but it takes a very long time to go through all my files. The folder I am checking typically contains about 600 files and sits on a Win 2K server. My Mac and the server are on 100 mps network but it takes my PowerBook G4 with OS 9.2 over an hour to complete the task. Does anyone have any suggestions on how I might rewrite the script to make it work faster???
tell application "Finder"
set killdate to date ((current date) - (11 * days))
set graphics_folder to folder "Graphics" of disk "Images"
set all_the_files to every file of folder graphics_folder as list
set num_of_files to length of all_the_files
repeat with i from 1 to num_of_files
set heres_a_file to item i of all_the_files
set mod_date to modification date of heres_a_file
if mod_date < killdate then
delete heres_a_file
end if
end repeat
end tell
Well, here’s a crazy idea. What if you gathered a list of mod dates and sorted through THAT list? Might that be faster? Instead of acting on each file. I’ll be honest, I have no idea, but it seems like a start. Anyone else? I’m still more intermediate than a “guru”. My bizarre theory is that if you didn’t have to act on a file until it was determined to be too old, it might be faster…? Naturally, you’d want to replace the “display dialog” command here (and the disk is replaced with a folder name on that server), with something like “delete file myFile of folder myFolder of disk that_Disk”
tell application "Finder"
set thelist to modification date of every item in disk "009"
set theDate to current date
repeat with e in thelist
if e < theDate then
display dialog ""
end if
end repeat
end tell
No need to sort - how about…
tell application "Finder" to delete (every item in theFolder whose modification date is less than ((current date) - (11 * days)))
No repeats, therefore a bit quicker… 
Dave L.
(I’ll try again, with some sensible formatting… 
No need to sort - how about…
tell application "Finder" to delete (every item in theFolder whose ¬
modification date is less than (( current date ) - ( 11 * days )))
No repeats, therefore a bit quicker… 
: Dave L.
WOW. . .is all I can say. Marc Myers suggestion about using the Akua Sweets method is the winner by a landslide. The task which formerly took over an hour was now finished in mere seconds. It took about 15 seconds, to be exact. Thanks to everyone for their interest and help and especially to Marc.—Tom