Printing in java - Create a table to print
Posted on 2007-11-21
i wonder if anyone can help.
I currently havea webapp that allows the user to print a table from the screen, and with css hide parts of the page that i do not want to print. But when there is a large number of rows in the table and it goes over 1 page, it looks messy and can cut halfway through a row.
I thought about using PrinterJob, but that creates a Graphice2d object for each page and then send it to the printer (if possible i could loop through the list(and for each page add 20 rows to it) but i have the problem that i do not have a clue how to create the tables using Graphice2d.
Cany anyone help me here, or have any suggestions how i can get this done.