3

The UWP RichEditBox automatically adds a new line to rtf when saving. You notice it when you load the saved RTF into a RichEditBox again. Is there a valid reason for this madness? Is it a bug? And most importantly, how do I remove it?

LeBrown Jones
  • 887
  • 6
  • 17
  • Could you please show me your code? I tried the MSDN [document](https://learn.microsoft.com/en-us/windows/uwp/design/controls-and-patterns/rich-edit-box#create-a-rich-edit-box) to save the content of RichEditBox into RTF file, it did not add a new line. – Xie Steven Apr 25 '18 at 03:00
  • Simply create a RichEditBox, use GetText to export the content as rich text. When you load that data back into the editor you will notice a new line. If you save it again, yet another newline will be added... This will happen perpetually. – LeBrown Jones Apr 25 '18 at 08:55
  • The document uses `editor.Document.SaveToStream` method, have you tried this way to see if it works for you? – Xie Steven May 07 '18 at 06:40
  • I have the same issue – BrunoVT Jan 21 '19 at 13:37

0 Answers0