Hi,
I using already Spire.Doc to convert from Doc to PDF and works very well. But now i need to make one conversion from HTML string to RTF string. Can you do this with Spire.Doc , and if i can please give me instructions
Thanks!
Dzenan
String HTML = "<H1>Spire.Doc for .NET</H1>";
//Create a new document
Document document = new Document();
//Add a section
Section sec = document.AddSection();
//Add a paragraph and append html string
sec.AddParagraph().AppendHTML(HTML);
//Save to RTF file
document.SaveToFile("Result.rtf", FileFormat.Rtf);
//Get the rtf string
string rtf = File.ReadAllText("Result.rtf");
String HTML = "<img src='https://www.e-iceblue.com/images/Intro/intro_office.png'/>";
//Create a new document
Document document = new Document();
//Add a section
Section sec = document.AddSection();
//Add a paragraph and append html string
sec.AddParagraph().AppendHTML(HTML);
//Save to RTF file
document.SaveToFile("Result.rtf", Spire.Doc.FileFormat.Rtf);
String HTML = File.ReadAllText("oneStringHtml.txt");
Document document = new Document();
Section sec = document.AddSection();
sec.AddParagraph().AppendHTML(HTML);
document.SaveToFile("Result.rtf", Spire.Doc.FileFormat.Rtf);