I am using iTextSharp for creating PDF for reports in ASP.Net (c#).
Pdf is created successfully & can be opened when running the Application, but when iam hosted in IIS it cannot open in PDF and gives error :
"adobe reader could not open pdf because it is either not a supported file type or because the file has been damaged "
My code like:
Document pdfDoc = new Document();
string filepath = "Demo" + ".pdf";
string attachment = "attachment; filename=" + filepath;
Response.Charset = String.Empty;
Response.ContentType = "application/PDF";
Please help me!!
I am waiting for your greatfull ideas !
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)