Can you show us the handler that empties a line...
Jeremy,
I believe from your description of the problem (no matter what line
is emptied the new text goes into line 10) that your logic is
deleting the line instead of emptying it.
If one starts with a 10-line variable, delete line x of
Sarah,
Aren't there possible issues if one changes the contents of the
control variable inside a repeat for each structure? For repeat for
each to work in this case wouldn't one need to make a copy of the
control variable for the repeat make changes to the original?:
on fillBlanks
Just recently I noticed a very strange 'bug'(?) in my code that I really
can't figure out There is a repeat script that checks each line of a
variable to see if it is empty, if it is then add data to that line. Certain
events will empty a random line (so line 2 would be empty but lines
Jeremy,
The only thing I can think of is that maybe your adding of data is
changing line numbers. Do you ever put more than one line worth of data
into that empty line? If so, that would throw off the count and give
you confusing results...
HTH
on Add_New
repeat with x = 1 to 10
if line x of
I don't know if this will help in your case, but as a general rule,
using a repeat for each loop is much faster. If you are only dealing
with 10 lines, it won't really matter, but you may deal with more data
later
This script will add data to lines 1 to 10 but then when lines are
emptied only