Mark Burns wrote: > Is there a more efficient way to write very large tables?
Yes, this is discussed in section 6.1.5 of the iText book 'Working with large tables' http://itext.ugent.be/itext-in-action more specifically on page 181 ('Memory management for large tables'). > Or is it possible to stream the document so that a few pages are visible > right > away and the rest of the document loads after? That's a completely different question. It's not related to tables. You're asking if iText supports Linearized PDF. It doesn't, and it doesn't have to. When used properly, iText is fast enough to produce a document with hundreds of pages in seconds (not hours). > I implemented the > example for giving a user a progress bar, but that is not very helpful > if it takes an hour to generate the doc (because users don't like to > wait for an hour). I do just the same for documents that take half a minute because of slow database access (on a very old D-Isam database that doesn't even understand SQL) and complex queries. I create the PDF in a Thread; I take the total number of rows that is to be expected, and serve an HTML progress bar showing the percentage of rows that has been added to the document so far. Note that this process is slow, not because of iText, but because of the database access. Of course, this is only true if you don't create the complete table (keeping all the rows in memory) before adding it to the document. There are different ways to add rows to the document before the table is finished. This is one of them: http://itext.ugent.be/itext-in-action/examples/chapter06/PdfPTableMemoryFriendly.java br, Bruno ------------------------------------------------------------------------- This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ _______________________________________________ iText-questions mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/itext-questions Buy the iText book: http://itext.ugent.be/itext-in-action/
