Re: Which bit of this simple script is wrong?
Re: Which bit of this simple script is wrong?
- Subject: Re: Which bit of this simple script is wrong?
- From: Shane Stanley <email@hidden>
- Date: Fri, 16 Aug 2002 08:47:39 +1000
On 16/8/02 12:47 AM +1000, Steve Thompson, email@hidden, wrote:
>
Tell application "Quark Xpress"
>
Return name of generic box 1 of document 1
>
--> "Place"
>
Exists generic box 1 of document 1
>
--> True
>
Exists generic box of document 1 whose name is "Place"
>
--> False
>
End tell
>
>
It has to be something about the way I'm phrasing it as the box named
>
"Place" obviously exists. To *me* the answer to Exists generic box of
>
document 1 whose name is "Place" is "true"
>
>
Could someone tell me how I check to see if something exists on a document
>
by name? Or if it's not possible (as name is an attribute not an object), is
>
there a way round it?
Either of these will work:
exists ((generic box 1 of document 1) whose name is "Place")
exists (generic box 1 whose name is "Place") of document 1
Your existing script is looking for a document called "Place".
--
Shane Stanley, email@hidden
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.