I apologize for the double send.  I have fat fingers today. 

I am not sure what the difference is then, but using the content disposition 
header absolutely would not work for me - unless I was using it in a save/open 
dialog directly from the browser.  I spent a full day trying to make it work.  
That's why I finally resorted to using the handler.

Thanks, 

Brian


-----Original Message-----

Date: Wed, 26 May 2010 11:06:48 -0400
From: Erik Pfingsten <[email protected]>
Subject: Re: [iText-questions] How to set the pdf's name dynamically
To: 'Post all your questions about iText here'
        <[email protected]>
Message-ID:
        <5494f850ca19724fbd13c96baa610b60592b53a...@cinmail01.cinci.paycor.com>
        
Content-Type: text/plain; charset="us-ascii"

Setting the Content-Disposition Header will work if you are opening the file in 
Adobe Reader first also (ie it will pre-fill the filename in the Save As box, 
but the end user can then change the name).  That's what I do.  

In C#:
String fileName = "whatever.pdf";
Response.AddHeader("Content-Disposition", string.Format("attachment; 
filename=\"{0}\"", fileName)); 

Erik Pfingsten




------------------------------------------------------------------------------

_______________________________________________
iText-questions mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/itext-questions

Buy the iText book: http://www.itextpdf.com/book/
Check the site with examples before you ask questions: 
http://www.1t3xt.info/examples/
You can also search the keywords list: http://1t3xt.info/tutorials/keywords/

Reply via email to