Replace
Sub Replace($source As String, $searchStr As String, $replaceStr As String) As String
Returns a string in which the specified substring is replaced with another substring.
Replace is case-insensitive.
Parameters
- $source ... String expression that contains the substring to replace.
- $searchStr ... Substring to search for.
- $replaceStr ... Substring used as the replacement.
Example:
Dim $s
$s = "This is a text"
$s = Replace($s, "text", "number")
' returns $s = "This is a number"