lowagie/iText rendering/display problem (objects getting corrupt??)
I have a problem in the resulting PDF generated using the lowagie/iText package. I think the problem relates to the objects (PdfPCell, PdfPTable, Paragraph, Phrase) somehow getting corrupted or garbage collected BEFORE they get put into the document with document.add() . This is just a guess. Here is our setup, and our symptoms: Setup ----- * J2EE on Solaris * Apache/IHS & WebSphere 3.5.5 Advanced Ed. (on Solaris) * Netscape webserver & NetDynamics 5.0 (on Solaris) * Both webservers and application servers are on the same machine * We output the PDF into a temporary file, and then display the temp file in the browser. Coding ------ * We are using iText 0.80 from the website * We are using PdfPTable and PdfPCell (instead of just Table and Cell) for our objects that we are putting into the document Symptoms -------- * When we click on the link to the cgi/servlet, the PDF that gets generated displays. * Repeatedly clicking the link results in PDFs that get generated that do NOT match (repeated clicks should produce IDENTICAL PDFs). * The problem appears in both browsers, IE and NS. * The problem also appears if you save the file in any browser and open in Acrobat (v4 or v5). * There are NO errors displayed when the document is opened either in the browser, or in Acrobat itself. Description ----------- The PDF that gets generated appears to have corrupt text (constructed as a Phrase or Paragraph). I am unsure how this is happening. By corrupt I mean that the text I am programmatically adding to document.add() is not what is appear in the document! That portion of the document can be blank, a streak of color, or anything other than what I tell it to be. The portion of the PDF that is not behaving correctly can CHANGE. That is, this is not specifically limited to the header, the footer, or any specific portion of the document. Unpredictably, some portion of the document gets corrupted in the resulting PDF. What I can say is this: Each click should result in the same PDF that gets generated. This is not always true. With enough clicks I might be lucky enough to generate a "full" PDF without any objects corrupted. It's almost as if the objects (PdfPCell, PdfPTable, Paragraph, Phrase, ...) I am creating and adding to the document are getting garbage collected or somehow corrupted!!! Any help with this is greatly appreciated. I am not sure how this is happening at all. If there is any information I am missing or need clarification on, let me know. Thanks, Tommy Tam Find the best deals on the web at AltaVista Shopping! http://www.shopping.altavista.com _______________________________________________ iText-questions mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/itext-questions
