The "key down option" has no effect on the result. The advanced
option does not appear. Any other ideas?
Thanks,
-Rhon
On 4/22/05, Christopher Hickman <email@hidden> wrote:
> I may have spoken too soon. I found key down and key up in
> Hidden.scriptSuite under System Events.app (While I don't have GUI access to
> a Mac, I do have ssh access).
>
> Try this, though I don't know if it will work:
>
> activate application "Printer Setup Utility"
> tell application "System Events"
> tell process "Printer Setup Utility"
> key down option
> click menu item "Add Printer." of menu "Printers" of menu bar item
> "Printers" of menu bar 1
> key up option
> end tell
> end tell
>
> -----Original Message-----
> From: Christopher Hickman [mailto:email@hidden]
> Sent: Friday, April 22, 2005 3:03 PM
> To: 'email@hidden'
> Subject: RE: Click menu item with option key down
>
> I'm replying just to you. I don't want to make extra traffic on the list for
> stuff I'm guessing wildly about, since I don't have a Mac I can test on.
> Does Add Printer have a key equivalent? If so you could use...
>
> keystroke "N" using (command and option)
>
> ...where "N" is the key equivalent. I was hoping there was a way to tell
> system events to keydown a modifier, then send the click, then keyup. I
> don't think you can, though.
>
> -----Original Message-----
> From: rfitz [mailto:email@hidden]
> Sent: Friday, April 22, 2005 2:36 PM
> To: Christopher Hickman
> Cc: email@hidden
> Subject: Re: Click menu item with option key down
>
> click: cause the target process to behave as if the UI element were clicked
> click UI element -- The UI element to be clicked.
> [at list] -- when sent to a "process" object, the { x, y }
> location at which to click, in global coordinates
> Result: UI element -- the reply for the command
>
> Above is the System Events Applescript Dictionary entry for the click
> command. Unfortunately I do not see anything about modifiers
> parameter. Hopefully I am wrong...
>
> -Rhon
> On 4/22/05, Christopher Hickman <email@hidden> wrote:
> > I don't have a Mac right now to test, but doesn't the click command have a
> > 'with modifiers' parameter? Check the System Events dictionary...
> >
> > Topher
> >
> > -----Original Message-----
> > From: applescript-studio-bounces+tophu=email@hidden
> > [mailto:applescript-studio-bounces+tophu=email@hidden] On
> Behalf
> > Of rfitz
> > Sent: Thursday, April 21, 2005 9:02 PM
> > To: AppleScript Studio
> > Subject: Click menu item with option key down
> >
> > How can I change the code below so that when the click action is
> > called, it sends a click with the option key down.
> >
> > activate application "Printer Setup Utility"
> > tell application "System Events"
> > tell process "Printer Setup Utility"
> > click menu item "Add Printer." of menu "Printers" of menu
> > bar item
> > "Printers" of menu bar 1
> > end tell
> > end tell
> >
> > In order to get the advanced menu item to appear, you need to hold
> > down the option key and either click the Add button or hold the option
> > key and select Add Printer from the Printers menu.
> >
> > Any suggestions would be appreciated.
> >
> > Thanks,
> >
> > -Rhon
> >
> > _______________________________________________
> > Do not post admin requests to the list. They will be ignored.
> > Applescript-studio mailing list (email@hidden)
> > Help/Unsubscribe/Update your Subscription:
> >
> http://lists.apple.com/mailman/options/applescript-studio/rfitzwater%40gmail
> .com
> >
> > This email sent to email@hidden
> >
>
> _______________________________________________
> Do not post admin requests to the list. They will be ignored.
> Applescript-studio mailing list (email@hidden)
> Help/Unsubscribe/Update your Subscription:
> http://lists.apple.com/mailman/options/applescript-studio/email@hidden
>
> This email sent to email@hidden
>
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-studio mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/applescript-studio/email@hidden
This email sent to email@hidden