Scripting what should be a simple loop...

Mark Wieder mwieder at ahsoftware.net
Fri Jul 9 23:33:00 CDT 2010


David-

Friday, July 9, 2010, 8:37:44 PM, you wrote:

>>It is recommendable to use arrays in this case:
>>
>>repeat for i = 1 to 10
>> put fld i of grp "AllFields" into tVar[i]
>>end repeat

> I'll really consider that to see if it will fit the need, Mark.
> Question: Is getting data into or out of an array any faster than a
> repeat loop used on regular variables?

Well, it's not regular variables that are the issue here. An array is
*MUCH* faster than a "do" statement. Do statements are very slow, and
I only use them sparingly and when there's no alternative. But when
you gotta, you gotta.

-- 
-Mark Wieder
 mwieder at ahsoftware.net




More information about the use-livecode mailing list