Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Inserting an HTML fragment into a WPF FlowDocument

I'm dynamically building a WPF FlowDocument from a datasource. One of the data elements is a fragment of HTML - I need to figure out a way to parse that and insert it into my FlowDocument.

I've found HTMLToXAMLConverter which will return a XAML representation of the HTML, but I'm still not sure how to best go about instantiating that XAML fragment so I can insert it into my FlowDocument.

like image 966
Jason Avatar asked Mar 30 '09 16:03

Jason


1 Answers

Answered my own question...

System.Windows.Markup.XamlReader.Parse()
like image 116
Jason Avatar answered Oct 19 '22 06:10

Jason