• 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
Accessing front window of Mail.app
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Accessing front window of Mail.app


  • Subject: Accessing front window of Mail.app
  • From: Mike Matthews <email@hidden>
  • Date: Sun, 6 Sep 2009 09:42:57 -0700

Hi:

I've been trying to find a way for this AppleScript (or something like it) to work:

tell application "Mail"
set theContent to the content of the front window
end tell

But it appears that there's no way to target the front window of Mail, including in the 10.6 version of Mail.

error "Mail got an error: Can’t get content of window 1." number -1728 from content of window 1

This fails as well:

tell application "Mail"
set theContent to the content of the front message
end tell

error "Mail got an error: Can’t get message 1." number -1728 from message 1

Anyone have an ideas?

The larger goal is to use an AppleScript to take various parts of a mail message (sender, content, etc.) from the front open Mail message window and copy it to a FileMaker database and then send the message. But this step has been problematic.

Worked like a charm in HyperCard, however..... ;)

TIA,
mm
 _______________________________________________
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: Accessing front window of Mail.app
      • From: Axel Luttgens <email@hidden>
    • Re: Accessing front window of Mail.app
      • From: Luther Fuller <email@hidden>
  • Prev by Date: new (I think) time question
  • Next by Date: Re: new (I think) time question
  • Previous by thread: Re: new (I think) time question
  • Next by thread: Re: Accessing front window of Mail.app
  • Index(es):
    • Date
    • Thread