Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

In a similar way to what gmail allows, I'd like to get specific senders' remote images to be auto-loaded.

One option that I came across is using a rule and an applescript:

However, this doesn't seem to work (at least on the current 10.7.3 - that solution is a bit outdated)

Any ideas how to fix this applescript or, alternatively, another way to achieve the desired end result?

share|improve this question
up vote 5 down vote accepted

You have been bitten by the brittleness of GUI Scripting solutions – viz. their dependency on the UI element hierarchy of the target application. In the case of, this hierarchy has changed rather drastically with Lion (no surprise there, as Lion’s was a rather drastic update from earlier versions). The correct UI address of the “Load Images” button is now

button 1 of UI element 1 of row 1 of table 1 of scroll area 1 of window

As this is rather a mouthful to chew on, I’d recommend modifying the original script to operate on a reference, changing the core GUI Scripting command as follows:

set loadButton to a reference to button 1 of UI element 1 of row 1 of table 1 of scroll area 1 of front window
if loadButton exists then click loadButton

Note, however, that this does not actually reproduce Gmail’s behavior – it will just open all mails meeting the rule condition(s) in a viewer window with inline server images displaying each time the rule is run. It does not affect inline message display (in the message preview column), nor does it apply when you open the message in a new window yourself. Barring writing your own plugin, there is nothing you can do about that, as the only event processing mechanism offers you can hook into with AppleScript is executing rules.

share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .