Font normalFont = new Font(Font.TIMES_ROMAN, 12, Font.NORMAL); PdfPTable table = new PdfPTable(2); Phrase phrase = new Phrase("Sample Text", normalFont); PdfPCell cell = new PdfPCell(phrase); cell.setBorderWidth(1); cell.setBorder(Rectangle.TOP); cell.setColspan(2); table.addCell(cell);
If I move the cell.setColspan(2), after the table.addCell(cell), the endless loop problem goes away but then the border is only applied to the first column.
I just started using iText, so I'm sure I'm missing something. I need the ability to use a specific font for text in a table and have borders on only the top and bottom of the table. If there is another way to accomplish this, I'd love to know.
Thanks, Tom
_________________________________________________________________
MSN 8 helps eliminate e-mail viruses. Get 2 months FREE*. http://join.msn.com/?page=features/virus
------------------------------------------------------- This SF.Net email sponsored by: Parasoft Error proof Web apps, automate testing & more. Download & eval WebKing and get a free book. www.parasoft.com/bulletproofapps1 _______________________________________________ iText-questions mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/itext-questions
