diff --git a/SUBQHSE/FineUIPro.Web/CQMS/ProcessControl/InspectionManagementStatistics.aspx b/SUBQHSE/FineUIPro.Web/CQMS/ProcessControl/InspectionManagementStatistics.aspx index a3d62bc..476ed17 100644 --- a/SUBQHSE/FineUIPro.Web/CQMS/ProcessControl/InspectionManagementStatistics.aspx +++ b/SUBQHSE/FineUIPro.Web/CQMS/ProcessControl/InspectionManagementStatistics.aspx @@ -49,9 +49,9 @@ - + - + diff --git a/SUBQHSE/FineUIPro.Web/CQMS/ProcessControl/InspectionManagementStatistics.aspx.cs b/SUBQHSE/FineUIPro.Web/CQMS/ProcessControl/InspectionManagementStatistics.aspx.cs index 8a00dbc..001c4ae 100644 --- a/SUBQHSE/FineUIPro.Web/CQMS/ProcessControl/InspectionManagementStatistics.aspx.cs +++ b/SUBQHSE/FineUIPro.Web/CQMS/ProcessControl/InspectionManagementStatistics.aspx.cs @@ -264,26 +264,16 @@ namespace FineUIPro.Web.CQMS.ProcessControl } } - protected void btnOut_Click(object sender, EventArgs e) { - DateTime dt = DateTime.Now; - string filename = dt.Year.ToString() + dt.Month.ToString() + dt.Day.ToString() + dt.Hour.ToString() + dt.Minute.ToString() + dt.Second.ToString(); - - Response.Clear(); - Response.Buffer = true; - Response.Charset = "GB2312"; + Response.ClearContent(); + string filename = Funs.GetNewFileName(); + Response.AddHeader("content-disposition", "attachment; filename=" + System.Web.HttpUtility.UrlEncode("控制点检查检测合格率统计" + filename, System.Text.Encoding.UTF8) + ".xls"); + Response.ContentType = "application/excel"; Response.ContentEncoding = System.Text.Encoding.UTF8; - Response.Write(""); - - Response.AppendHeader("Content-Disposition", "attachment;filename=" + System.Web.HttpUtility.UrlEncode("控制点检查检测合格率统计" + filename, System.Text.Encoding.UTF8) + ".xls"); - Response.ContentType = "application/ms-excel"; - this.EnableViewState = false; - System.IO.StringWriter oStringWriter = new System.IO.StringWriter(); - System.Web.UI.HtmlTextWriter oHtmlTextWriter = new System.Web.UI.HtmlTextWriter(oStringWriter); - this.Grid1.RenderControl(oHtmlTextWriter); - Response.Write(oStringWriter.ToString()); - Response.Flush(); + this.Grid1.PageSize = this.Grid1.RecordCount; + this.BindGvInspectionManagement(null); + Response.Write(GetGridTableHtml(Grid1)); Response.End(); } } diff --git a/SUBQHSE/FineUIPro.Web/CQMS/ProcessControl/InspectionManagementStatistics.aspx.designer.cs b/SUBQHSE/FineUIPro.Web/CQMS/ProcessControl/InspectionManagementStatistics.aspx.designer.cs index edf38b2..10bece3 100644 --- a/SUBQHSE/FineUIPro.Web/CQMS/ProcessControl/InspectionManagementStatistics.aspx.designer.cs +++ b/SUBQHSE/FineUIPro.Web/CQMS/ProcessControl/InspectionManagementStatistics.aspx.designer.cs @@ -123,12 +123,12 @@ namespace FineUIPro.Web.CQMS.ProcessControl protected global::FineUIPro.Button btnOut; /// - /// lblPageIndex 控件。 + /// lblNumber 控件。 /// /// /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::System.Web.UI.WebControls.Label lblPageIndex; + protected global::System.Web.UI.WebControls.Label lblNumber; } }