• 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
Re: Stuck with GUI scripting
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Stuck with GUI scripting


  • Subject: Re: Stuck with GUI scripting
  • From: Brett Conlon <email@hidden>
  • Date: Tue, 13 Dec 2005 11:36:34 +1000


Hi Bill,

Many thanks for your response!

I've managed to get the pop up button working with the below code. I stumbled on the answer when I tried to re-create the code to work with Safari to see if it was just FreeHand having the issue.

When I issued the Print command to Safari (outside of System Events) it just went and printed the loaded web page without producing the Print dialog so I had to turn to using the SystEv code to make the Print dialog appear and the rest just worked from there... I then translated the code back to FreeHand and it also worked!!!:

tell application "FreeHand MX"
        activate
        tell application "System Events"
                tell process "FreeHand MX"
                        click menu item "Print..." of menu 1 of menu bar item "File" of menu bar 1
                        delay 1
                        click pop up button 1 of window "Print"
                        delay 1
                        click menu item "FreeHand MX" of menu of pop up button 1 of window "Print"
etc...

And thanks for the pointers about the AX actions!

Regards,

Cojcolds



Bill Cheeseman <email@hidden>

on 2005-12-12 12:35 AM, Brett Conlon at email@hidden wrote:

> I'm trying to select the "FreeHand MX" menu item of the pop up button (1) of
> the Print window but nothing is happening further than the Print window
> appearing.
>
> Here's the code:
>
> tell application "FreeHand MX"
>         activate
>         tell document 1
>                print
>                tell application "System Events"
>                        tell process "FreeHand MX"
>                               click menu item "FreeHand MX" of pop up button 1
> of window "Print"
>                        end tell
>                end tell
>         end tell
> end tell


 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: Stuck with GUI scripting
      • From: Bill Cheeseman <email@hidden>
References: 
 >Re: Stuck with GUI scripting (From: Bill Cheeseman <email@hidden>)

  • Prev by Date: Re: faxing
  • Next by Date: RE: find and replace question mark in Quark 6.5
  • Previous by thread: Re: Stuck with GUI scripting
  • Next by thread: Re: Stuck with GUI scripting
  • Index(es):
    • Date
    • Thread