1
I have the following code fragment:
Document doc = new Document(PageSize.A4.rotate());
while(iteratorRow.hasNext()){
Object valorCelulaRow = iteratorRow.next();
if ( valorCelulaRow != null ) {
Paragraph p = new paragraph();
p.add ( valueCellRow.toString() );
doc.Add( ( Element ) p ); // ERRO 1 ALTERNATIVA
doc.Add( p ); //ERRO - 2 ALTERNATIVA
}
}
I searched the itext guide, but did not find a solution to this problem.
http://itextpdf.com/examples/iia.php?id=12
http://itextpdf.com/book/examples.php
...
Why add the variable twice
p
?– David Schrammel
Hello David. Thank you for answering. Manage to solve this problem. Now my pdf file is loading blank, even bringing results with the test I did in debug mode. The full code is here: http://stackoverflow.com/questions/32335038/how-to-insert-the-values-in-page-pdf-with-itext-pdf/32336441?noredirect=1#comment52547174_32336441
– Paulo Victor
Actually gives error while opening the file. seems to be corrupted
– Paulo Victor