• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
AppleScript to move messages between mailboxes in Apple Mail
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

AppleScript to move messages between mailboxes in Apple Mail


  • Subject: AppleScript to move messages between mailboxes in Apple Mail
  • From: Jashanjeet Singh <email@hidden>
  • Date: Wed, 21 Jul 2010 22:21:34 +0530

Hi,
To move a message from one mailbox to another mailbox in Apple Mail,
the mailbox property of the message is changed to a specified mailbox.
The following example code would change the mailbox of selected
message to the specified mailbox named Filed.
tell application “Mail”
  set theSelection to selection
  set theMessage to item 1 of theSelection
  set mailbox of theMessage to mailbox “Filed”
end tell

Above code works on the user selection. It moves the first message
from the selection done by the user.
My question is that is it possible to move messages from one mailbox
to another by telling the Mail application that move first 5 messages
of the mailbox "Inbox" to mailbox "Filed" without selecting the
messages that needs to move.

Thanks
Jashan
 _______________________________________________
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

  • Follow-Ups:
    • Re: AppleScript to move messages between mailboxes in Apple Mail
      • From: Michelle Steiner <email@hidden>
    • Re: AppleScript to move messages between mailboxes in Apple Mail
      • From: Luther Fuller <email@hidden>
  • Prev by Date: File size problem
  • Next by Date: Re: Has anyone created a script for AD 2008 home and shares in OS X.5/6?
  • Previous by thread: Re: File size problem
  • Next by thread: Re: AppleScript to move messages between mailboxes in Apple Mail
  • Index(es):
    • Date
    • Thread