creating rules for mailboxes by using apple script
creating rules for mailboxes by using apple script
- Subject: creating rules for mailboxes by using apple script
- From: "qas qwes" <email@hidden>
- Date: 25 Jul 2006 12:56:29 -0000
Dear Apple friends ,
I am writing an apple script in which rule for each mailbox has to be created . The script
is looping through all mailboxes , it has to check whether there is rule existing for the
mailbox , if not create a rule for the existing box. The simple rule is if a when mail message
is recieved from particular sender_name@domain_name transfer that mail to this this
mailbox .Any help or clue to where I can get the answer will be highly appreciated . Just
suggest me proper syntax for this case . The rough outline of the script is :
tell application "Mail"
--getting the mailboxes
set all_mailboxes to mailboxes of account "IMAP Account"
--looping through the mail box
repeat with each_mailboxes in all_mailboxes
--getting the name of mailbox
set mail_boxname to name of each_mailboxes
--get the unique sender_name@domain_name list_sender from the each_mailbox
--make a rule for the list_senders
syntax required
end repeat
end tell
The other part of the script is working fine , I just want to know how to add rule to this
particilar mailbox in a loop . The version of the mail application is 2.1 . Is there is also any
way to add the rules to the existing rules ?
Thanks in advance
Krishna
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden