Looping over all buttons

J. Landman Gay jacque at hyperactivesw.com
Wed Feb 22 12:41:05 EST 2012


On 2/22/12 11:12 AM, Bob Sneidar wrote:
> not for.
>
> repeat with x = 1 to the number of buttons of this card
>    do "put the hilite of button x into button"&  x
>    -- a better way
>    put the short name of button x into ButtonHilitesA[x]["name"]
>    put the hilite of button x into ButtonHilitesA[x]["state"]
> end repeat
>
> Now you have a numbered array of button names and states.

I wouldn't use "do". Every time it runs, the whole compiler has to load.

Unduly doing do is doo doo.

-- 
Jacqueline Landman Gay         |     jacque at hyperactivesw.com
HyperActive Software           |     http://www.hyperactivesw.com




More information about the use-livecode mailing list