Index: basic/source/runtime/methods.cxx =================================================================== --- basic/source/runtime/methods.cxx (revision 1634275) +++ basic/source/runtime/methods.cxx (working copy) @@ -1439,7 +1439,7 @@ if( nPos != STRING_NOTFOUND ) { aExpStr.Replace( nPos, nFindStrLen, aReplaceStr ); - nPos = nPos - nFindStrLen + nReplaceStrLen + 1; + nPos = nPos + nReplaceStrLen; nCounts++; } else @@ -1448,7 +1448,7 @@ } } } - rPar.Get(0)->PutString( aExpStr.Copy( static_cast(lStartPos - 1) ) ); + rPar.Get(0)->PutString( aExpStr.Copy() ); } }