Spire.PDFViewer is a powerful PDF Viewer component for .NET. It allows developers to load PDF document from stream, file and byte array.

Tue Jun 09, 2020 2:57 pm

Sorry, I need a suggestion; how can is possible to show a PDF from an HTML static file?
I tried to use LoadFromHtml method but don't works moreover I found an article says this method will be dismissed in the future. Is that true?

Thank you very much for your reply
Damiano

damiano.viezzi@olipress.it
 
Posts: 9
Joined: Tue Mar 05, 2019 8:12 am

Wed Jun 10, 2020 6:11 am

Hello,

Thanks for your inquiry.
Yes, the LoadFromHtml method is now obsolete and may be removed in the future. For your requirement, you can first use our Spire.PDF to convert the HTML file to PDF, and then displaying the PDF file with our Spire.PDFViewer. Meanwhile, there is another method to convert HTML to PDF using plugins, you can also try it.
Here I made a demo for you, please directly run it on your side. If you have further questions, please feel free to contact us.
http://www.e-iceblue.com/downloads/demo/21824Demo.zip

Sincerely,
Rachel
E-iceblue support team
User avatar

rachel.lei
 
Posts: 1571
Joined: Tue Jul 09, 2019 2:22 am

Fri Jun 12, 2020 8:44 am

Thank you very much for your solution.
Greetings
Damiano

damiano.viezzi@olipress.it
 
Posts: 9
Joined: Tue Mar 05, 2019 8:12 am

Wed Jun 17, 2020 10:02 am

Hello,

You are welcome.
If you need further assistance, just feel free to contact us.
Wish you all the best!

Sincerely,
Rachel
E-iceblue support team
User avatar

rachel.lei
 
Posts: 1571
Joined: Tue Jul 09, 2019 2:22 am

Return to Spire.PDFViewer