I have to use style to not lose the trace of highlighted text because the user can change the color without generate the document (only reapply styles with the selected color). String textToInsert = “This a test with highlight” ī = new HandleNodeFont(font) ī = null To insert text in document, I’m using builder.InsertHtml: Style style = (StyleType.Paragraph, “Heading 4”) Private static void CreateHighlightStyle(ref Document doc, Color color)īool hightlightStyleExists = ().Any(s => s.Name = “Heading 4”) This is my code when I create the Word document ![]() This is the style for H4 in my RichText page ![]() It works, but I have useless line feed before and after the highlighted text. I don’t how can I “convert” css class to word style. I have problem to highlight html text provided from a RichText.
0 Comments
Leave a Reply. |