Mail not triggering rule script?
Mail not triggering rule script?
- Subject: Mail not triggering rule script?
- From: Jakob Peterhänsel <email@hidden>
- Date: Thu, 2 Aug 2007 22:41:24 +0200
Hi All,
I have a script that is supposed to trigger on incoming mail, and
send a customized reply.
Now, the script work - when I select Apply Rules from, the Message
menu, and does all it's stuff, but it does NOT trigger on 'new mail'
in the inbox.
This is on a Mac mini PPC.
Now, if I run it on my MBP, it Does trigger (well.. 95% of the time)
automatically.
If I remove the AppleScript action, and just make the rule 'Play
Sound', it triggers fine.
Anybody have a clue???
Script is this:
property replytext : "!! DENNE MAIL KAN IKKE BESVARES !!
Tak for din Tilmelding.
Vi har registreret dine data.
Du vil hører nærmere angående optagelse på holdet efter
tilmeldingsfristen slutter 15 august.
Skulle du have spørgsmål, er du velkommen til at kontakte
kontaktpersonen for det hold du ønsker at gå på, eller en fra
bestyrelsen. Kontaktinfo er på hjemmmesiden og i programmet.
Venligst,
Salto City
--------------------------
"
using terms from application "Mail"
on perform mail action with messages theMessages ¬
for rule theRule
tell application "Mail"
repeat with thisMessage in theMessages
set theHeader to (content of header "reply-to") of thisMessage
--set org_sender_ to reply to of theHeader
--set name_ to extract name from sender_
set address_ to extract address from theHeader
log "The address: " & address_
set subject_ to "AUTOSVAR: " & subject of thisMessage
set boby_ to replytext & content of thisMessage
set new_message to (make new outgoing message at the beginning of
outgoing messages with properties {subject:subject_,
sender:"email@hidden", content:boby_})
tell new_message
make new to recipient at beginning of to recipients with
properties {address:address_}
end tell
save new_message
--beep
send new_message
say "Message handled"
end repeat
end tell
end perform mail action with messages
end using terms from
Thanks,
Jakob Peterhänsel
"Be a part of the Love Generation - carry a smile, not a gun."
- JP, May 2006
Email: email@hidden
AIM: Marook
Phone: +45 29687104
_______________________________________________
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