str := StringReplace(str,'[','',[rfReplaceAll]); str := StringReplace(str,']',#13#10,[rfReplaceAll]); memo1.lines.text := str;