Re: Where is the Missing Link?.
Re: Where is the Missing Link?.
- Subject: Re: Where is the Missing Link?.
- From: Jolly Roger <email@hidden>
- Date: Tue, 25 Sep 2001 10:42:11 -0500
On 9/25/2001 9:32 AM, "Rachel Cogent" <email@hidden> wrote:
>
Last by 2 AM I finally became frustrated to tears at how to do this most
>
rudimentary operation in AppleScript Which 2 days ago I described in DOS
>
batch terms:
>
DIR/s>textfile
>
This command makes a directory list of all files and all files in all
>
subdirectories and writes the output to "textfile".
Hi Rachel,
AppleScript technology is massive on Mac OS; so it's bound to be
overwhelming to a beginner. Just try to be patient and ask lots of
questions. It'll come to you.
On to your problem... If you don't mind using a scripting addition, then
you could do it very easily using FindFile
<
http://microcosmsoftware.com/findfileosax.html>:
-- begin script
set someFolder to choose folder
-- get the file listing
set folderContents to FindFile in_folder someFolder with files, folders and
subfolders
-- write the file
set fileRef to open for access ((someFolder as text) & "Contents.txt") with
write permission
repeat with nextItem in folderContents
write nextItem & return to fileRef
end repeat
close access fileRef
-- end script
JR