putting a relative large amount of data into a field

Robert Brenstein rjb at rz.uni-potsdam.de
Thu Jun 26 06:52:00 EDT 2003


>Goodmorning everybody,
>
>Just a small question. Did anybody encounter the following problem?
>If a "relative" large amount of data contained in a variable is put 
>into a field, the field doesn't show all the data although it seems 
>to be present.
>To force all the data in the variable to be seen in the field, one 
>has to copy it to the field in smaller chunks.
>I tested the following scripts on several computers in the vicinity 
>(only OS X and that's the why of the question) and they all showed 
>the same problem.
>(the scripts give a different mileage in Revolution and Metacard, 
>although they use the same engine)
>
>on mouseUp
>   put "" into fld "output"
>   lock screen
>   repeat with i = 1 to 10000
>     put i & ", " after b
>   end repeat
>   delete last char of b
>   put b into fld "output"
>   select after fld "output"
>   put the number of items in fld "output"
>end mouseUp
>

Have you tried to remove the lock screen? May be it interferes here?

What is the purpose of select after? To have a blinking cursor after 
the inserted text? The side effect of this may be that the field 
scrolls, so it may also affect the screen update. May be you should 
try doing this select through a time-delayed send to allow all other 
updates to proceed as scheduled.

Last, what about having enough memory? Field updates require some 
extra internal buffers in the engine. I know because I have a program 
that updates a field regularly while other activity is going on, and 
for some reason (memory fragmentation of some sort) results in memory 
leak.

Robert



More information about the use-livecode mailing list