Parameters
- expression
- Required. String expression containing substring to replace.
- find
- Required. Substring being searched for.
- replacement
- Required. Replacement substring.
- start
- Optional. Position within expression where substring search is to begin. If omitted, 1 is assumed.
- count
- Optional. Number of substring substitutions to perform. If omitted, the default value is –1, which means "make all possible substitutions."
- compare
- Optional. Numeric value indicating the kind of comparison to use when evaluating substrings. See Settings for values.
Return Value
If find is zero-length or Nothing, Replace returns copy of expression. If replacement is zero-length, Replace returns copy of expression with no occurrences of find. If expression is zero-length or Nothing, or start is greater than length of expression, Replace returns Nothing. If count is 0, Replace returns copy of expression.