Welcome Guest Search | Active Topics | Sign In | Register

HtmlToPdf - How to calculate height of dynamic footer? Options
mandar
Posted: Monday, June 19, 2023 3:15:37 PM
Rank: Newbie
Groups: Member

Joined: 6/19/2023
Posts: 1
Hi,

I need some help in calculating footer content height, to maintain a consistent bottom margin of 0.5 inch and request inputs with the same.
We are required to render a footer on all pdf pages. The footer's content may vary, depending on application logic.

The formula to calculate the footer position and content OutputArea for HtmlToPdfOptions, is as follows:
OutputArea = new RectangleF(
MMToInch(0.5f),
MMToInch(0.5f),
MMToInch(0.5f - 0.5f - 0.5f),
MMToInch(0.5f - 0.5f - 0.5f) - footerHeight),

I couldn't find an API to calculate the footerHeight, so I could shrink or expand the main content dynamically, based on the footer contents, which could sometimes be empty (no footer) or could go upto 3 lines.

EO.pdf version - 21.1.67.0

Thanks in advance,
Mandar


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.