hello,
I am trying to write an AppleScript that works with Mail.app so that whenever the conditions of this rule are satisfied, the AppleScript will run using the triggering message. Obviously, I will add to this skeleton later, but I have been trying to debug this for a while, and I am not really getting anywhere… what is the problem preventing the script from running?
Condition(s) in Mail.app for this rule: Every message
using terms from application "Mail"
on perform mail action with messages message_list for rule this_rule
tell application "Mail"
display dialog "Running Rule AppleScript!"
repeat with received_message in message_list
set theSubject to (the subject of received_message) as text
display dialog theSubject
end repeat
end tell
end perform mail action with messages
end using terms from