Re: Running Scripts from Mail Rules
Re: Running Scripts from Mail Rules
- Subject: Re: Running Scripts from Mail Rules
- From: email@hidden
- Date: Fri, 27 Oct 2017 17:29:19 -0400
Back to my real script - I can’t even get PROPERTIES of a message.
I always get the "Got message” speech.
But it never displays a dialog, or does anything after that.
using terms from application "Mail"
on perform mail action with messages Msgs
set N to count of Msgs
say "Messages: " & N
repeat with i from 1 to N
say ("Start " & i)
try
set M to item i of Msgs
say ("Got message")
display dialog (properties of M)
set Nm to (sender of M)
say ("Got sender")
set S to (extract name from (sender of M) as
rich text)
say ("You have new mail from " & S)
on error
display dialog (errMsg as rich text)
end try
say ("end " & i)
end repeat
end perform mail action with messages
end using terms from
----------------------------------------------------------------
Steve Bird
Culverson Software - Elegant software that is a pleasure to use.
www.Culverson.com (toll free) 1-877-676-8175
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden