Re: Entourage > Filemaker
Re: Entourage > Filemaker
- Subject: Re: Entourage > Filemaker
- From: JollyRoger <email@hidden>
- Date: Tue, 19 Dec 2000 15:04:11 -0600
on 12/19/2000 2:31 PM, Jacco Rens at email@hidden wrote:
>
So:
>
>
on run
>
tell application "Microsoft Entourage"
>
set ThisList to selection
>
repeat with This_Msg in ThisList
>
set message_Subject to subject of This_Msg
>
set message_Body to content of This_Msg
>
set message_Address to sender of This_Msg
>
set message_Sender to (display name of senderAddress)
>
tell me to write_record()
>
end repeat
>
end tell
>
end run
>
on write_record()
>
tell application "FileMaker Pro"
>
create record at end of database "Applescripts email archive" with
>
data ,
>
{message_Subject, message_Body, message_Address}
>
end tell
>
end write_record
>
>
>
Seemed a good starting point, but it gives me errors on the "message_subject
>
is not defined" hmm I thought I told it to set itself right?
>
>
This is realy a chicken and egg story, how can I search for the right syntax
>
if it's not in my filemaker database :-)
Applescript is correctly informing you that message_Subject has not been
defined in the write_record() handler, which indeed is the case. You need
to make message_Subject a property, or declare it global in both handlers -
otherwise, the scope of the message_Subject variable you set is limited to
the run handler.
Another partially-related note: I tried coming up with a solution like this
for Outlook Express. After all was said and done, I found that simply
dragging messages to a folder in the Finder is a far better method of
backing up email messages. The attachments are automatically saved in each
message. A utility like BBEdit can be used to search for certain messages.
And Outlook Express is far more stable using this method rather than
Applescript for backing up large numbers of messages.
HTH
JR