Re: Mail scripting
Re: Mail scripting
- Subject: Re: Mail scripting
- From: Robert Poland <email@hidden>
- Date: Thu, 14 Aug 2003 07:13:46 -0600
JD and others.
I found out why the script wasn't working for ruels. The following
worked just fine:
on perform_mail_action(info)
tell application "Mail"
set selectedMessages to |SelectedMessages| of info
set theRule to |Rule| of info
repeat with eachMessage in selectedMessages
set theSubject to subject of eachMessage
set theRuleName to name of theRule
set theText to "The rule named '" & theRuleName & "' B,
matched this message:" & return & return & B,
"Subject: " & theSubject
display dialog theText
end repeat
end tell
end perform_mail_action
What was lacking in the previous scripts was the "_" in
perform_mail_action, I think.
Maybe I'm propagating a bad habit, but I usually just type end and
let the editor finish the line.
--
Bob Poland - Englewood, CO
http://www.ibrb.org/
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.