(I can work in either OS 9 or X; am therefore posting this topic in 2 forums.)
I have a project that needs to be completed tomorrow.
It involves creating 120 text files containing the names of 120 image files.
I am of course desperately searching for
an AppleScript that can do the job for me.
To be more exact, what it needs to do is read the names of
files in a given folder and for each one create a text file containing
the name of the original file, and then save each file in the same
folder. The files could have the same names as the originals but with a
.txt suffix.
Bill Cheeseman has done me the favor of outlining how such a Script would run; I can’t write ApppleScript myself, or I would take it from here. Does anyone have a little time? I’m afraid I can offer no money for this, but I might be able to drum up a paying job in the future for aomeone who helps me now. Please contact me at atik@shinyheadgraphics.com
from Bill:
-
choose folder – puts up a dialog where the user can choose the folder
-
tell the Finder to repeat with every file in the folder whose kind is
jpeg (or whatever) -
tell the Finder to get the name of the file
-
open for access a file with the same name + ‘.txt’ in the same folder
-
set the text (contents) of the file to the name
-
close access the file
-
end repeat