Response.AppendHeader("Content-Disposition", "inline; filename=doc1.pdf");
Response.AppendHeader("Content-Disposition", "attachment; filename=doc1.pdf");
Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.
Have a better answer? Share it in a comment.
From novice to tech pro — start learning today.
http://msdn.microsoft.com/en-us/library/system.web.httpresponse.binarywrite(v=vs.110).aspx
First, the file needs to be a byte array:
byte[] myPDFBytes = <some byte array representing the PDF>;
Open in new window