• 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
Requesting assistance with 'Mail' app
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Requesting assistance with 'Mail' app


  • Subject: Requesting assistance with 'Mail' app
  • From: Brian Christmas <email@hidden>
  • Date: Sat, 13 Dec 2014 10:08:43 +1100

G’day scripters

Yosemites ‘Mail’ has been cut off at the knees. 

When trying to access the ‘File/Save Attachments..’ menu from a script opened message, the menu item remains greyed out.

No amount of GUI clicking on the interface that I’ve tried has worked.

I really, really need that menu item activated, so I’m hoping that wiser heads than mine can advise me of a way (yes. it’s you lot I’m referring to).

I’ve tried the following (which I’ve also posted on the ‘Mail’ forum), but Mail no longer responds to clicks, it seems.

Any remedies, please?

Regards

Santa

set SaveAttachmentsMenu to true
tell application "Mail"
  activate
  set WindowCount to count of windows
  open item 1 of messages of mailbox "* items to store" # drafts mailbox
  set x to 0
  repeat # wait until the message is really open.
  tell current application to delay 0.1
  set x to x + 1
  if x > 40 then exit repeat
  if (count of windows) > WindowCount then exit repeat
  end repeat
  tell application "System Events" to tell process "Mail"
  tell current application to delay 1
  try
  select scroll area 1 of window 1
  click
  end try
  try
  tell scroll area 1 of window 1
  set {xPosition, yPosition} to position
  set {xSize, ySize} to size
  end tell
  -- modify offsets if hot spot is not centered:
  click at {xPosition + (xSize div 2), yPosition + (ySize div 2)}
  display dialog xPosition & tab & yPosition as text
  on error errmsg
  display dialog errmsg
  end try
  tell current application to delay 0.2
  if exists menu item "Save Attachments…" of menu 1 of menu bar item "File" of menu bar 1 then
  keystroke "a" using command down
  if not enabled of menu item "Save Attachments…" of menu 1 of menu bar item "File" of menu bar 1 then say"attachments disabled"
  click menu item "Select All" of menu 1 of menu bar item "Edit" of menu bar 1
  set x to 0
  try
  click menu item "Save Attachments…" of menu 1 of menu bar item "File" of menu bar 1
  end try
  repeat until exists sheet 1 of window 1
  tell current application to delay 0.1
  set x to x + 1
  if x = 40 then
  set SaveAttachmentsMenu to false
  exit repeat
  end if
  end repeat
  end if
  end tell
end tell
SaveAttachmentsMenu
 _______________________________________________
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: Requesting assistance with 'Mail' app
      • From: Yvan KOENIG <email@hidden>
  • Prev by Date: Re: Quicktime frame rate calculation error
  • Next by Date: Re: Requesting assistance with 'Mail' app
  • Previous by thread: Re: Quicktime frame rate calculation error
  • Next by thread: Re: Requesting assistance with 'Mail' app
  • Index(es):
    • Date
    • Thread