# Replace$

Result = Replace$ ( String , Pattern , ReplaceString )

Replaces every occurrence of the string Pattern in the string String by the string ReplaceString , and returns the result .

- If String is null, then a null string is returned.

- If Pattern is null, then the string String is returned.

Examples

    PRINT Replace$("Gambas is basic", "bas", "BAS")

    GamBAS is BASic

    PRINT Replace$("Gambas is basic", "a", "")

    Gmbs is bsic

    PRINT Replace$("Gambas is basic", " ", "--")

    Gambas--is--basic

See also

LTrim$ | Left$ | Lower$ / LCase$ | Mid$ | RTrim$ | Replace$ | Right$ | Space$ | Split | String$ | Subst$ | Trim$ | Upper$ / UCase$