StringReplace function
String / Filename routines |
![]() ![]() ![]() |
acUtils
|
type
|
TReplaceFlags = set of (rfReplaceAll, rfIgnoreCase);
|
|
function StringReplace(const S, OldPattern, NewPattern: String; Flags: TReplaceFlags): String;
|
The StringReplace function replaces occurrences of the substring specified by OldPattern with the substring specified by NewPattern parameter. StringReplace assumes that the source string, specified by S, may contain Multibyte characters.
|
|
If the Flags parameter does not include rfReplaceAll, StringReplace only replaces the first occurrence of OldPattern in S. Otherwise, all instances of OldPattern are replaced by NewPattern.
|
|
If the Flags parameter includes rfIgnoreCase, The comparison operation is case insensitive.
|
This function used in the AppControls for Delphi 2/3 and BCB 1/3 only. In the Delphi 4 and later please use same routine from standard SysUtils unit.
|