Show contents 

System > System Assembly Classes > String > String.Replace

String.Replace

Syntax

Replace(Source: String; OldValue: String; NewValue: String): String;

Parameters

Source. Source string.

OldValue. The substring that should be replaced with a new value.

NewValue. Replace substring.

Description

The Replace method searches for occurrence of the substring passed by the OldValue parameter, to the Source string and replaces it with the value passed by the NewValue parameter.

Example

Sub UserProc;
Var
    s, s1: String;
Begin
    s := "abcdcefc";
    s1 := String.Replace(s, "c""*");
End Sub UserProc;

After executing the example the "s1" variable contains the ab*d*ef* value.

See also:

String