• 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
Scripting Mail.app
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Scripting Mail.app


  • Subject: Scripting Mail.app
  • From: Reinhold Penner <email@hidden>
  • Date: Fri, 11 Jan 2002 12:36:13 -1000

I have a few questions about scripting OS X's Mail application. Does anyone know how to accomplish the following from AS:

tell "Mail" to fetch new mail
tell "Mail" to open its main window when it's closed
tell "Mail" to select the first mailbox that contains unread messages

So in essence, what I want to do is the following:

tell application "Mail"
activate
-- check if main window exists - if so, bring it to front - if not, open it
-- check mail on IMAP account
-- select first unread message (if not possible then select INBOX)
end tell

TIA for any pointers,

-Reinhold


  • Prev by Date: Re: Problems with Smile 1.8.4 and system 9.2.2
  • Next by Date: Re: Please Pass the Handler
  • Previous by thread: Re: Please Pass the Handler
  • Next by thread: Re: Scripting Mail.app
  • Index(es):
    • Date
    • Thread