Welcome Guest Search | Active Topics | Sign In | Register

Predict height of HTML Options
LINQ IT
Posted: Thursday, March 9, 2017 1:33:16 PM
Rank: Advanced Member
Groups: Member

Joined: 11/8/2015
Posts: 42
I'm printing a report that needs to print on a predefined form. As part of the contents that will print, there is a notes area that may or may not contain notes and can only take up a certain amount of room. If it goes over this room, I need to create another pdf document with this information. Is there a way to determine height of this HTML?
eo_support
Posted: Saturday, March 11, 2017 3:55:23 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,229
Hi,

You will need to do that with JavaScript. What you can do is to use this method to run JavaScript code in the browser engine:

https://www.essentialobjects.com/doc/eo.pdf.htmltopdfsession.execscript_overloads.aspx

If you are not familiar with HtmlToPdfSession object, you can find more details here:

https://www.essentialobjects.com/doc/pdf/htmltopdf/session.aspx

We do not provide support on exactly how to determine whether the contents of the notes exceeded a set size using JavaScript though, that you can research online. If you have any questions about the converter or our API, please feel free to ask.

Thanks!


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.