HTML to PDF / Doc?

Technical support for Spire.DataExport

Moderators: iceblue support, DataExport, Manager

HTML to PDF / Doc?

Postby jduty » Wed Oct 13, 2010 5:26 pm

Will DataExport convert HTML to PDF or Doc format?

Thanks
jduty
 
Posts: 1
Joined: Wed Oct 13, 2010 5:21 pm

Re: HTML to PDF / Doc?

Postby admin » Thu Oct 14, 2010 1:54 pm

Sorry, Sprie.DataExport can't convert html to pdf/doc, but you can use Spire.Doc to convert html to PDF/DOC, our support team will provide you a demo tomorrow to show that.
User avatar
admin
Site Admin
 
Posts: 3
Joined: Thu Jan 01, 1970 12:00 am

Re: HTML to PDF / Doc?

Postby admin » Fri Oct 15, 2010 4:52 pm

using Spire.Doc convert html to pdf/doc:

Spire.Doc.Document document = new Spire.Doc.Document();
document.LoadFromFile("test.html", Spire.Doc.FileFormat.Html);

//convert to doc
document.SaveToFile("test.doc", Spire.Doc.FileFormat.Doc);

//convert to pdf
document.SaveToFile("test.pdf", Spire.Doc.FileFormat.PDF);
User avatar
admin
Site Admin
 
Posts: 3
Joined: Thu Jan 01, 1970 12:00 am

Re: HTML to PDF / Doc?

Postby saminathanb » Mon Jan 31, 2011 10:36 pm

i tried with loadfromfile method , it gives error may be it validating the HTML Doc .
i needs to load without validation ( my HTML Doc contains only table elements).

i able to open the same file in MS Word Application without error
saminathanb
 
Posts: 2
Joined: Mon Jan 31, 2011 9:05 pm

Re: HTML to PDF / Doc?

Postby harry.support » Wed Feb 02, 2011 4:08 pm

Please try
Code: Select all
Document document = new Document();
document.LoadFromFile("your.html", FileFormat.Html, XHTMLValidationType.None);
Harry
Technical Support / Developer,
e-iceblue Support Team
User avatar
harry.support
 
Posts: 180
Joined: Mon Nov 08, 2010 3:11 pm


Return to Spire.DataExport

Who is online

Users browsing this forum: No registered users and 0 guests