Here is a handy function that I sometimes use in my Lotus Script programs. 

'===============================================================================
' +----------------------------------------------------------------------------+
' | Function: strreplace
' +----------------------------------------------------------------------------+
' | Accepts: src, the value to search for to replace.
' |          dest, the value to replace with.
' |          arg, the string to search within.
' +----------------------------------------------------------------------------+
' | Description:
' | Replaces all occurances of src with dest in the string arg.
' +----------------------------------------------------------------------------+
'===============================================================================
Public Function strreplace(Byval src As String, Byval dest As String,
Byval arg As String) As String

    'Declare variables
    Dim pos As Integer

    'Initialize
    pos = Instr(arg, src)

    'Loop through the string
    While (pos > 0)
        arg = Left(arg, pos - 1) + dest + Mid(arg, pos + Len(src))
        pos = Instr(pos + Len(dest), arg, src)
    Wend

    'Return the replaced string
    strreplace = arg

End Function

Here is an example of how to use the function:

newString = strreplace("WORLD", "World", "Hello WORLD!")

The newString variable would contain “Hello World!”