When an AppleScript is run from a rule in Entourage, what is the correct way to determine the context (the messages) over which the script applies. If I say:
on run
Tell application “Microsoft Entourage”
set foo to current messages
– do stuff to each of them
end tell
end run
This does not work. However if I select the messages and run the script it does work. How is the script supposed to know what the new messages are? Do I have to look for all the messages in the mailbox marked as unread?
Does Entourage call a script handler, passing the new messages list? I can’t seem to find much information on scripting Entourage on Microsoft’s site.
Thanks
Tom