|
Is the regular expressions version of command REPLACE. Finds all sub strings they match Expr1 inside variable av and replaces them with Expr2. Searching is case sensitive. Expr1 is a regular expression. NOTE: To use a replace string (Expr2) which is adapted and composed with the each time found sub string we can use the constant MATCH to represent the found string in the replace string. e.g.
After the execution of the above code the following will be printed:
See REPLACE, Regular expressions. See also an alternative more powerful version of this command below. |
|
If you need the maximum flexibility in find and replace use this version of REReplace command. Instead of a replace string parameter takes a local function which is used in the replace process. This function must have only one normal (IN) parameter. Every time REReplace call this function it passes in its parameter the currently matched string and expects from the user to return the replacement for it. e.g.
|