Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
inserting and replacing lines of text from functions
#4
Example:

Code:
Copy      Help
str s ss
ss.getmacro("function0")
foreach s ss
,out "s now contains %s" s
,;...

Assume, whole text is in function0.
getmacro stores function0 text into variable ss.
foreach repeatedly executes following code, each time extracting new line.
The line is stored in variable s. You can use s in a way you want.

To repeatedly execute code, you probably used rep or for. Here instead is used foreach.


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)