导出PPT格式,像EXCEL/WORD一样,会自动弹出一个对话框,有 打开、保存、取消 三个按钮!
------解决方案--------------------------------------------------------
string filepath = Server.MapPath("~/xx.ppt");
string filename = System.IO.Path.GetFileName(filepath);
Response.Clear();
Response.ContentType = "application/octet-stream";
Response.AddHeader("Content-Disposition", "attachment; filename=" + filename);
Response.Flush();
Response.WriteFile(filepath);
Response.End();