显示我用一个处理程序来获取和使用下面的代码显示在浏览器窗口中的PDF:PDF不会在浏览器窗口中
byte[] byt = RetrieveDocument(int.Parse(context.Request.Params["id"]), context.Request.Params["title"]);
string file = WriteDocumentFilePDF(byt);
HttpContext.Current.Response.ContentType = "application/pdf";
HttpContext.Current.Response.AddHeader("content-length", byt.Length.ToString());
HttpContext.Current.Response.AddHeader("Content-Disposition", "inline; filename=programdetails.pdf");
HttpContext.Current.Response.BinaryWrite(byt);
HttpContext.Current.Response.End();
功能WriteDocumentFilePDF成功的PDF写入temp目录。我有上面的代码在不同的应用程序中正常工作。我错过了什么吗?