using variables as references?
Posted: Sun Mar 07, 2010 9:22 am
Is there a way to use variable references to replace or change text/strings the variable references?
For example in a repeat structure you use a variable to represent lines, words, array elements etc.
However when you change the variable k the original is not changed. If I used
I could use the number reference to change things in the original but the "for each" is way faster. Before picking up RR recently I have been using lua. In lua you can make a variable reference to another value and changing the variable reference changes the original. I suppose I could use a counter variable but the text processing is enormous and I worry about speed issues.
For example in a repeat structure you use a variable to represent lines, words, array elements etc.
Code: Select all
repeat for each line k in myVariable
replace "#" with empty in k
end repeat
Code: Select all
repeat with i=1 to the lines in myVariable