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!

Debenu Quick PDF Library - PDF SDK Community Forum Homepage
Forum Home Forum Home > For Users of the Library > I need help - I can help
  New Posts New Posts RSS Feed - Tables in PDF spanning several pages
  FAQ FAQ  Forum Search   Register Register  Login Login

Tables in PDF spanning several pages

 Post Reply Post Reply
Author
Message
stakon View Drop Down
Team Player
Team Player


Joined: 09 Oct 09
Status: Offline
Points: 22
Post Options Post Options   Thanks (0) Thanks(0)   Quote stakon Quote  Post ReplyReply Direct Link To This Post Topic: Tables in PDF spanning several pages
    Posted: 16 Sep 10 at 10:57AM
Hi all,


I have some really lengthy tables i want to put in a PDF.
The documentation on tables notes that DrawTableRows will only draw as much of a table as it fits in the current page.

Is there any alternative? Some function that continues drawing my table across several pages?
If not, is there any trick some of you have used to make this happen?

Thanx in advance,

stakon.
Back to Top
Rowan View Drop Down
Moderator Group
Moderator Group
Avatar

Joined: 10 Jan 09
Status: Offline
Points: 398
Post Options Post Options   Thanks (0) Thanks(0)   Quote Rowan Quote  Post ReplyReply Direct Link To This Post Posted: 20 Oct 10 at 2:21PM
Hi Stakon,

Sure, you can draw a table across multiple pages using DrawTableRows. 

When you call the DrawTableRows function there is a 'Height' parameter that will determine the area in which table rows can be drawn. If the rows being drawn exceed that area, then the DrawTableRows function will return the number of the last drawn row. This information can be used as a starting point for drawing the next row on the second page. When you call this function you don't have to start at row 1, you can start at row 101 if you want. Your table will still be in memory after DrawTableRows finishes on the first page.

SelectPage(1)
DrawTableRows
SelectPage(2)
DrawTableRows
SelectPage(3)
DrawTableRows

You just keep doing this until you haven't got any more rows in your table to draw.

Cheers,
- Rowan.
Back to Top
pdfOakleaf View Drop Down
Beginner
Beginner


Joined: 24 Oct 10
Status: Offline
Points: 10
Post Options Post Options   Thanks (0) Thanks(0)   Quote pdfOakleaf Quote  Post ReplyReply Direct Link To This Post Posted: 24 Oct 10 at 12:30AM
sorry if this is a daft question but I've only just started with this library

SelectPage(1)
DrawTableRows

how do you know which rows have been drawn and which are still to be rendered?


Many thanks
Phil

Back to Top
pdfOakleaf View Drop Down
Beginner
Beginner


Joined: 24 Oct 10
Status: Offline
Points: 10
Post Options Post Options   Thanks (0) Thanks(0)   Quote pdfOakleaf Quote  Post ReplyReply Direct Link To This Post Posted: 24 Oct 10 at 12:35AM
Or is it just a case that I just have to work out how many rows will fit on the first page, render them,
then add a new page and continue the rendering until I reach the end of the table.

I'm quite happy to do that unless there's an elegant solution.

Thanks Again (great product by the way)
Phil
Back to Top
pdfOakleaf View Drop Down
Beginner
Beginner


Joined: 24 Oct 10
Status: Offline
Points: 10
Post Options Post Options   Thanks (0) Thanks(0)   Quote pdfOakleaf Quote  Post ReplyReply Direct Link To This Post Posted: 24 Oct 10 at 12:59AM
having read the documentation for DrawTableRows more thoroughly I have worked this out

It's a very impressive  libary.

Phil
(next time I'll read more and post less)
Back to Top
Rowan View Drop Down
Moderator Group
Moderator Group
Avatar

Joined: 10 Jan 09
Status: Offline
Points: 398
Post Options Post Options   Thanks (0) Thanks(0)   Quote Rowan Quote  Post ReplyReply Direct Link To This Post Posted: 26 Oct 10 at 9:30PM
Great -- I'm glad to hear that you were able to resolve the issue. Thanks for keeping us updated.

Cheers,
- Rowan.
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 11.01
Copyright ©2001-2014 Web Wiz Ltd.

Copyright © 2017 Debenu. Debenu Quick PDF Library is a PDF SDK. All rights reserved. AboutContactBlogSupportOnline Store