Porovnávané verzie

Kľúč

  • Tento riadok sa pridal
  • Riadok je odstránený.
  • Formátovanie sa zmenilo.

%ReplaceStr function


Function
The function replaces one substring by other one in the input string.
Declaration


Blok kódu
languageesl
themeConfluence
TEXT %ReplaceStr(
   TEXT in text, 
   TEXT in sub1, 
   TEXT in sub2, 
   BOOL in ReplaceAll
 )
Parameters


textText.
sub1String that to be replaced by a new one.
sub2String that replaces the previous one.
timeA@TRUE - replace all occurrence of sub1.
@FALSE - replace the first occurrence from the left only.
Example


Blok kódu
languageesl
themeRDark
%ReplaceStr("Name : % or %","%","John",@FALSE)   ; returns text: "Name : John or %" 
 
 %ReplaceStr("Name : % or %","%","John",@TRUE)    ; returns text: "Name : John or John"