Loading ...
Sorry, an error occurred while loading the content.

13528Re: replace across line breaks in a Str?

Expand Messages
  • Hugo Paulissen
    Apr 1, 2005
    • 0 Attachment
      Hi sgilbert92,

      > But when I try to use StrReplace on the text block, the line breaks
      > boggle it. Any suggestion besides the not-so-elegant approach of
      > replacing all line breaks with QQQ or something, doing StrReplace on
      > the offending special characters, and then converting the QQQ's back
      > to line breaks?
      > I'm good with ^!Replace, but that only works on active docs, right,
      > not vars?

      That is correct - you could send your variable to a file and then do
      the ^!Replace on that, but that may not be necessary...

      I am not sure what you mean with "the line breaks boggle it". Could
      you send an example of your code?

      If I run this clip on your mail I get a block of text without line-

      ^!Set %Temp1%=^$strReplace("this";"that";"^$getClipboard$";0;0)$
      ^!Set %Temp2%=^$strReplace("Word";"MS WORD";"^%Temp1%";0;0)$
      ^!Set %Temp3%=^$strReplace("^P";" ";"^%Temp2%;0;0)$
      ^!INFO ^%Temp3%


    • Show all 2 messages in this topic