Page 1 of 1
Lists all controls of a card ?
Posted: Sun Jan 14, 2007 2:54 pm
by xApple
I've gone thru the whole dictonary of transcript terms searching for something that would simply list all the controls present on a given card... to no avail.. any simple way of doing this ?
Help greatly appriciated.
My dream:
Code: Select all
put the controls of card 1 into myObjects
repeat with x = 1 to the number of lines of my myObjects
set the someProp of (line x of myObjects) to someValue
end repeat
Re: Lists all controls of a card ?
Posted: Sun Jan 14, 2007 3:08 pm
by marielle
May your wildest dreams come true
Code: Select all
repeat with x= 1 to (the number of controls of this card)
put the long id of control x of this card into tCtlRef
set the iAmAControlOfThisCard of tCltRef to true
if word 1 of tCtlRef is "field" then set the fontsize of tCtlRef to 16
end repeat
(typed on the fly and untested... feel free to correct me)
Posted: Sun Jan 14, 2007 3:12 pm
by xApple
nice, nice... using the numerical index of every object, of course !
This varies depending on the layer I recall...
Thanks a lot ! Have a nice sunday.
Posted: Mon Jan 15, 2007 5:06 pm
by Mark
I like using a property: put the objects of this card, put the objectIDs of this card.
getProp objects
repeat with x = 1 to number of controls of the target
put the name of control x of the target & return after myList
end repeat
sort myList
return myList
end objects
getProp objectIDs
repeat with x = 1 to number of controls of the target
put the id of control x of the target & return after myList
end repeat
sort myList
return myList
end objectIDs
Best,
Mark