On Friday, September 26, 2003, at 10:16 PM, Bojsza wrote:


I have a large file that I have loaded into a field "incoming". I wish to parse particular text pieces out into another field "outgoing".

The text is always between "value=question?>" and ends with "<" #the quotes are not part of the text

example

value=question?> TEXT I WISH TO PARSE OUT<

Any suggestions would be helpful (I have several hundred lines to search through).

I good job for regular expressions. Using regex the solution might vary depending if each a match is allowed to span more than one line or not. One solution could be:


local tResult
repeat for each line tLine in fld "incoming"
  if matchText(tLine, "value=question\?>(.+)<", tMatch) then
    put tMatch & linefeed after tResult
  end if
end repeat
put tResult into fld "outgoing"


Alex Rice <[EMAIL PROTECTED]> | Mindlube Software | http://mindlube.com


what a waste of thumbs that are opposable
to make machines that are disposable  -Ani DiFranco

_______________________________________________
use-revolution mailing list
[EMAIL PROTECTED]
http://lists.runrev.com/mailman/listinfo/use-revolution

Reply via email to