>I cut and pasted the code provided exactly as it appeared. Setting the MEMOWIDTH TO > 79 caused un-expected line breaks. I tried 80, 81, 82, 90, and 100 - all exhibited similar problem. At 79 or less it works well...
Would space trimming of each line fix the problem? Please try
lcNewtext = lcNewText + ALLTRIM(MLINE(lcText,i)) + CHR(13)
--sb--