1

I am using Spire.PDF for .NET to create pdf file and I have following problem with table pagination:

On every page I have header and footer so I need to set paginate bounds so that table doesn't go over header and footer and I do that like this:

tableLayout.PaginateBounds = new RectangleF(0, headerHeight, page.Canvas.ClientSize.Width, page.Canvas.ClientSize.Height - headerHeight - footerHeight);

and then I draw table with:

PdfLayoutResult result = table.Draw(page, new PointF(0, y), tableLayout);

Problem appears when I need some text before table, so table doesn't start immediately after header but it starts on some y > headerHeight. In that case table is drawn immediately after header, over text so y from "table.Draw(page, new PointF(0, y), tableLayout)" is ignored.

Can this even be achieved with Spire PDF and how?

jbojcic
  • 954
  • 1
  • 11
  • 25

1 Answers1

1

You can find answer here:

http://www.e-iceblue.com/forum/post13653.html#p13653

The problem was that I used wrong way to create header and footer. That should be done using top and bottom space and not as shown in E-iceblue tutorials for header and footer.

jbojcic
  • 954
  • 1
  • 11
  • 25