Mailing Lists: Apple Mailing Lists
Image of Mac OS face in stamp
RE: UI scripting
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: UI scripting



Hi Yvan,

I think I have the case correct as I copied from UI Browser, also I do have a sketch selected before I run the script. I keep on getting the NSReceiveEvalutionScriptEditor: 4 error message at first "click" command.

Ruby


-----Original Message-----
From: Yvan KOENIG [mailto:email@hidden]
Sent: Thursday, October 12, 2006 7:25 AM
To: AppleScript User's List
Subject: Re: UI scripting


Le 11 oct. 2006 à 16:58, Ruby Madraswala a écrit :


Hello

point 1 - It seems that the process name is case sensitive.
point 2 - if nothing is selected, the Copy menu item is disabled
which may explain the described result.

I assumes that with the added test you will get rid of the error
message.

activate application "Illustrator"
tell application "System Events" to tell process "Illustrator" to
tell menu bar 1 to tell menu bar item 4 --"Edit"
	click -- open Edit menu
	tell menu 1 to if enabled of menu item 5 then tell menu item 5 to
click -- choose Copy command
end tell


Yvan KOENIG



 _______________________________________________
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

 _______________________________________________
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



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2011 Apple Inc. All rights reserved.