0

I want to dynamically adjust height of the page to fit on one page base on content.

The problem is because I want to use "paper tape printer" and when it prints half or more of the page can be empty, so the idea is to dynamically adjust the size of the page (to fit on one page) based of the content and then print this page. The content can varray so it is really hard to calculate the size manually.

Is there any work around?

ButterBeast
  • 521
  • 10
  • 25
  • 1
    Please consult the official documentation, more specifically the free ebook [The Best iText Questions on StackOverflow](http://pages.itextpdf.com/ebook-stackoverflow-questions.html). In that book you'll find a reference to the question [Adjust page height to content height](http://stackoverflow.com/questions/27186661/adjust-page-height-to-content-height) which is an almost exact duplicate of what you are asking here. – Bruno Lowagie Aug 06 '15 at 10:17
  • May be this link will help you to solve this problem [ http://stackoverflow.com/questions/14958396/how-to-resize-a-pdfptable-to-fit-the-page – Albin Aug 06 '15 at 10:33

0 Answers0