コード例 #1
0
        public ActionResult ReportToExcel2(string ReportID, string Params, string dbConnStringKey, int pageIndex = 1, int perCount = 99999)
        {
            var path = reportServices.ToExcel(
                ReportID,
                Params,
                GetProjectDir("UserFiles\\Report\\Template.xlsx"),
                GetProjectDir("UserFiles\\Report\\报表.xlsx"),
                dbConnStringKey);

            return(Content("/" + ToVirtualPath(path)));
            //return Content(path,
            //    "application/zip-x-compressed", "报表.xlsx"
            //    );
        }