1) How to convert FlowDocument to string?
2) How to convert my string to FlowDocument?
FlowDocument contains text and pictures.
The text in the string should be preserved. Text12345
Pictures must be converted. For example, encoded: iVBORw0KGgoAAAANSUhEUgAAAFAAAABQCAYAAACOEfKtAAAABHNCSV
Text12345
iVBORw0KGgoAAAANSUhEUgAAAFAAAABQCAYAAACOEfKtAAAABHNCSV
Text67890
<text>
Text12345
<encoded_image>
iVBORw0KGgoAAAANSUhEUgAAAFAAAABQCAYAAACOEfKtAAAABHNCSV
</encoded_image>
Text67890
</text>
XAML:
<RichTextBox x:Name="textrich" >
<FlowDocument >
<Paragraph/>
</FlowDocument>
</RichTextBox>