Problems with paragraph.AppendHTML()

Technical support for Spire.Doc

Moderator: iceblue support

Problems with paragraph.AppendHTML()

Postby benjamin.gast » Mon Nov 05, 2012 5:20 pm

Hello,

I've got some trouble with the mehtod "paragraph.AppendHTML".
My HTML-String:
Code: Select all
Line 1<br><b>Line 2</b><br><i>Line 3</i><br><u>Line 4</u><br><br>Bulletpoints:<br><ul><li>safdsdfs</li><li>sdfsdfsdfsdfsdf</li><li>sdfsfsdfsdfsdfsdfsdf</li></ul><p>Numberlist:</p><ol><li>test 1</li><li>test 2</li><li>test 3</li></ol><p align="center">CENTER<br></p>


Output ends after Line 4.
Image
Image

Whats wrong?

Greetings from Germany
benjamin.gast
 
Posts: 2
Joined: Thu Mar 29, 2012 2:53 pm

Re: Problems with paragraph.AppendHTML()

Postby amy.zhao » Tue Nov 06, 2012 4:52 am

Hi benjamin.gast,

Thanks for your inquiry.
We have done a test, but we don't reproduce your problem. We use the dlls of Spire.Doc Pack (Hot Fix) Version:4.5.9 from the link http://www.e-iceblue.com/Download/download-word-for-net-now.html to test below code. If we miss something, please tell us.
Code: Select all
Document document = new Document();
 string htmlText=@"Line 1<br/><b>Line 2</b><br/><i>Line 3</i><br/><u>Line 4</u><br/><br/>Bulletpoints:<br/><ul><li>safdsdfs</li><li>sdfsdfsdfsdfsdf</li><li>sdfsfsdfsdfsdfsdfsdf</li></ul><p>Numberlist:</p><ol><li>test 1</li><li>test 2</li><li>test 3</li></ol><p align=""center"">CENTER<br/></p>";
document.AddSection().AddParagraph().AppendHTML(htmlText);
document.SaveToFile("sample.doc",FileFormat.Doc);


Best regards,
Amy
E-iceblue support
You do not have the required permissions to view the files attached to this post.
User avatar
amy.zhao
 
Posts: 2263
Joined: Wed Jun 27, 2012 8:50 am

Re: Problems with paragraph.AppendHTML()

Postby benjamin.gast » Tue Nov 06, 2012 8:11 am

Thanks amy,

your code helped me to fix my problem!
benjamin.gast
 
Posts: 2
Joined: Thu Mar 29, 2012 2:53 pm

Re: Problems with paragraph.AppendHTML()

Postby amy.zhao » Thu Nov 29, 2012 1:23 am

Hello,

You are welcome.
If you encounter any problem, please feel free to contact us.

Best regards,
Amy
E-iceblue support
User avatar
amy.zhao
 
Posts: 2263
Joined: Wed Jun 27, 2012 8:50 am


Return to Spire.Doc

Who is online

Users browsing this forum: No registered users and 0 guests