Title: Scripting creation of message draft window
I'm having a little AppleScript trouble and I'm hoping someone can point out the probably obvious error of my ways.
I have the following script:
--begin script
property theAddress : "remo @ mac.com"
property theRecipient : "[EMAIL PROTECTED]"
tell application "Microsoft Entourage"
set thesubject to "Test Subject"
set theBody to "Test body"
make new draft window with properties {subject:thesubject, content:theBody, account:theAddress, to recipients:theRecipient}
end tell
--end script
As you can see, I’m trying to define the account to send the message from by name, but I’m failing at either defining the "theAddress" property or the property of the draft window correctly or both. As written, the script compiles, but errors with the following when run:
Microsoft Entourage got an error:
Expected a reference
With the error occurring in the "make new draft window" line. If I remove "account:theAddress," the script runs fine, but the draft window has the default account. Could some kind soul explain the correct syntax for this? I'd prefer to define the sending account by name rather than having to figure out the ID of the account (besides, wouldn't the ID change if the database were rebuilt?).
Thank you.
-Remo Del Bello
--
"Oh, sure, you can use facts to prove anything that's even remotely true!"
- Homer Simpson
- Re: Scripting creation of message draft window Remo Del Bello
- Re: Scripting creation of message draft window Paul Berkowitz
- Re: Scripting creation of message draft window Remo Del Bello
- Re: Scripting creation of message draft window Allen Watson
- Speed on E'rage 2001/OS9 vs EvX/OSX Jan Martel
- Re: Speed on E'rage 2001/OS9 vs EvX/O... Allen Watson
- Re: Speed on E'rage 2001/OS9 vs EvX/O... Allen Watson
- Re: Speed on E'rage 2001/OS9 vs EvX/O... SVEN AERTS
- Re: Scripting creation of message draft wi... Remo Del Bello
- Re: Scripting creation of message draft wi... Paul Berkowitz
- Re: Scripting creation of message draft wi... Paul Berkowitz
