我想在浏览器窗口中显示 *doc,*xls,*pdf 而不是他们尊敬的应用程序。我尝试了以下代码,但没有运气,它提示我保存/打开对话框,而不是在浏览器中显示
//Set the appropriate ContentType.
Response.ContentType = "Application/msword";
//Get the physical path to the file.
string FilePath = MapPath("wordfile.doc");
//Write the file directly to the HTTP content output stream.
Response.AppendHeader("Content-Disposition", "inline;filename=" + "wordfile.doc");
Response.WriteFile(FilePath);
Response.End();
请帮忙
谢谢