On or near 2/27/01 7:17 AM, Wes Plate at [EMAIL PROTECTED] observed:

> I'd like to make it so that instead of always writing out a new file, it
> appends information to the same file every time.  Is that possible?

Sure. You could change this:

        write s to fileRef

to this:

        write s to fileRef starting at eof

Of course, the way the script is now, it makes a new file for every message
with a unique name. You'd need to take out the part that creates a new name
and names the file. Just hard-code the file name into the open statement in
the script. Showing the whole segment you'd need to change:

        set p to path to desktop folder as string
        -- To specify a particular folder other than the Desktop, replace
the
        -- line above with something like this, using your own names:
        -- set p to "MyDisk:Documents:Saved Mail:"
        set fn to makeName(subj)
        set fileRef to open for access (file (p & fn)) with write permission
        write s to fileRef
        close access fileRef
        tell application "Finder"
            activate
            set the file type of file (p & fn) to tcode
            set the creator type of file (p & fn) to ccode
        end tell

will become:

        set p to path to desktop folder as string
        -- To specify a particular folder other than the Desktop, replace
the
        -- line above with something like this, using your own names:
        -- set p to "MyDisk:Documents:Saved Mail:"
        set fn to "mymailarchive.txt"
        set fileRef to open for access (file (p & fn)) with write permission
        write s to fileRef starting at eof
        close access fileRef

You could then delete the entire "makename" handler, from "on makename" to
"end makename".
-- 
Peace,
Allen Watson <[EMAIL PROTECTED]> XNS name: =Allen Watson
A Mac family since 1984 <http://home.earthlink.net/~allenwatson/>
Applescripts for Outlook Express and Entourage:
<http://homepage.mac.com/allenwatson/>


-- 
To unsubscribe:               <mailto:[EMAIL PROTECTED]>
To search the archives: 
          <http://www.mail-archive.com/entourage-talk%40lists.boingo.com/>

Reply via email to