Sorry for the lack of details.
Some Details:
ASP.Net/C#, VS 2008
Some Pseudo-Code: (I have pretty much followed the examples I have found from
the tutorial site)
Create new document (_document = New Document)
Create new MemoryStream (m = New MemoryStream)
Create new Writer (writer = PdfWriter.GetInstance(_document, m))
Add a page footer
Open the document
Add some text to the document
Loop
Create a table, add some rows to the table, etc
Add the table to the document
End Loop
Close the Document (this always happens, so yes, the document is being closed)
Return the MemoryStream for Download
Response.ContentType = "application/octet-stream";
Response.AddHeader("Content-Disposition", string.Format("attachment;
filename=\"{0}\"", filename));
Response.OutputStream.Write(m.GetBuffer(), 0, m.GetBuffer().Length);
Response.OutputStream.Flush();
Response.OutputStream.Close();
Response.End();
Erik Pfingsten
Paycor, Inc. - Programmer / Analyst
644 Linn Street, Suite #200
Cincinnati, OH 45204
Ph: 513-338-5836
x. 2363
-----Original Message-----
From: Paulo Soares [mailto:[email protected]]
Sent: Friday, April 10, 2009 1:36 PM
To: Post all your questions about iText here
Subject: Re: [iText-questions] Adobe Error Popup
Forgot to close the pdf? Forgot to set the content-length? Forgot to tell us
how you are creating the pdfs?
Paulo
----- Original Message -----
From: "Erik Pfingsten" <[email protected]>
To: <[email protected]>
Sent: Friday, April 10, 2009 5:19 PM
Subject: [iText-questions] Adobe Error Popup
When I open any documents I created using iTextSharp, there is a brief
message popping up in Acrobat.
It says "The file is damaged and is being repaired", then the file loads and
seems to be fine.
I was wondering if anyone else has seen this with iText or iTextSharp?
Erik Pfingsten
Paycor, Inc. - Programmer / Analyst
644 Linn Street, Suite #200
Cincinnati, OH 45204
Ph: 513-338-5836
ext. 2363
This message, including any attachments, may contain information
which is confidential and privileged. Unless you are the addressee (or
authorized to receive for the addressee), you may not read, use, copy
or disclose to anyone the message, its attachments, or any information
contained therein. If you have received the message in error, please
advise the sender by reply e-mail and delete the message and any
attachments.
------------------------------------------------------------------------------
This SF.net email is sponsored by:
High Quality Requirements in a Collaborative Environment.
Download a free trial of Rational Requirements Composer Now!
http://p.sf.net/sfu/www-ibm-com
_______________________________________________
iText-questions mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/itext-questions
Buy the iText book: http://www.1t3xt.com/docs/book.php
This message, including any attachments, may contain information
which is confidential and privileged. Unless you are the addressee (or
authorized to receive for the addressee), you may not read, use, copy
or disclose to anyone the message, its attachments, or any information
contained therein. If you have received the message in error, please
advise the sender by reply e-mail and delete the message and any
attachments.
------------------------------------------------------------------------------
This SF.net email is sponsored by:
High Quality Requirements in a Collaborative Environment.
Download a free trial of Rational Requirements Composer Now!
http://p.sf.net/sfu/www-ibm-com
_______________________________________________
iText-questions mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/itext-questions
Buy the iText book: http://www.1t3xt.com/docs/book.php