Quantcast
Channel: Windows Presentation Foundation (WPF) forum
Viewing all articles
Browse latest Browse all 18858

How can I insert an Image in WPF RichEdit at runtime

$
0
0

Hi,

I have a WPF RichText Box and I can type values to it. If I need to paste an EMF file, I am overriding the OnPaste command and need to paste the image. 

  Paragraph para = new Paragraph();
   para.Inlines.Add(myImage3);
   richTextBox.Document.Blocks.Add(para);

This is not getting insert at the next Caret position. Is there any similar method for adding image similar to 

richTextBox.CaretPosition.InsertTextInRun();


Viewing all articles
Browse latest Browse all 18858

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>