Returns a new string in which all occurrences of a specified string in the current instance are replaced with another specified string.
![]()
A string that is equivalent to the current string except that all instances of oldValue are replaced with newValue. If oldValue is not found in the current instance, the method returns the current instance unchanged.
If newValue is null, all occurrences of oldValue are removed.
This method does not modify the value of the current instance. Instead, it returns a new string in which all occurrences of oldValue are replaced by newValue.
This method performs an ordinal (case-sensitive and culture-insensitive) search to find oldValue.