Do you own a Debenu Quick PDF Library version 7, 8, 9, 10, 11, 12, 13 or iSEDQuickPDF license? Upgrade to Debenu Quick PDF Library 14 today!
![]() |
HTML to PDF |
Post Reply ![]() |
Author | |
waynefulcher ![]() Senior Member ![]() ![]() Joined: 23 Jun 08 Location: United States Status: Offline Points: 99 |
![]() ![]() ![]() ![]() ![]() Posted: 09 Aug 12 at 11:01PM |
Can anyone tell me if I have a program that reads the text from an HTML file, If there is any way at all to use QuickPDF (I am on 8.16) to convert the HTML to a PDF... heres the catch. I want to specify a "pagesize" like "letter" then I want the function to automatically create enough pages in the PDF to render all of the HTML in porportion. I see the DrawHTML() method but if the rendered HTML is so long it takes 10 pages to draw it all then how do I handle that?
If there is no simple one call method to do this is there some work-a-round? Thanks Wayne |
|
![]() |
|
AndrewC ![]() Moderator Group ![]() ![]() Joined: 08 Dec 10 Location: Geelong, Aust Status: Offline Points: 841 |
![]() ![]() ![]() ![]() ![]() |
Wayne,
This code might be useful QP.NewDocument(); QP.SetOrigin(1); string s = File.ReadAllText("input.html"); QP.DrawBox(10, 10, 300, 500, 0); string overflow = QP.DrawHTMLTextBox(10, 10, 300, 500, s); while (overflow != "") { QP.NewPage(); QP.DrawBox(10, 10, 300, 500, 0); overflow = QP.DrawHTMLTextBox(10, 10, 300, 500, overflow); } QP.SaveToFile("out.pdf"); |
|
![]() |
Post Reply ![]() |
|
Tweet
|
Forum Jump | Forum Permissions ![]() You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |
Copyright © 2017 Debenu. Debenu Quick PDF Library is a PDF SDK. All rights reserved. About — Contact — Blog — Support — Online Store