The following script is not working. Evidently, I don’t know the proper syntax for assigning a project to an Entourage message. Can someone lend a hand? Thanks.
tell application "Microsoft Entourage"
set theProject to "Strategic Planning"
set SelectedMessages to current messages
if SelectedMessages is {} then
display dialog "Please select a message first and then run this script." with icon 1
return
end if
repeat with theMessage in SelectedMessages
set the project of theMessage to theProject
end repeat
end tell
Model: MacBook Pro
AppleScript: 1.10.6
Browser: Safari 417.9.3
Operating System: Mac OS X (10.4)
Am I the only one who finds the answer five minutes after I post? Geesh!
I found this at http://www.entourage.mvps.org/faq_topic/project_script.html
property yourproject : "Strategic Planning"
tell application "Microsoft Entourage"
-- get the currently selected message or messages
set SelectedMessages to current messages
-- if there are no messages selected, warn the user and then quit
if SelectedMessages is {} then
display dialog "Please select a message first and then run this script." with icon 1
return
end if
repeat with theMessage in SelectedMessages
-- get the project list from the message, add "YourProject" to it
set theProject to project list of theMessage
if {project yourproject} is not in theProject then
copy project yourproject to end of theProject
set project list of theMessage to theProject
end if
end repeat
end tell