前台
<asp:ImageButton ID="btnDownLoad" runat="server" Height="16px"
ImageUrl="~/paReport/Images/sucaiwcom7804000eyu.gif"
οnclick="btnDownLoad_Click1" Width="16px" />
C#的下载到excel
string filename = "SSL_WIP_Data_" + DateTime.Now.ToString("yyyy-MM-dd");
Response.Clear();
Response.Buffer = true;
Response.Charset = "utf-8";
Response.AppendHeader("Content-Disposition", "attachment;filename=" + System.Web.HttpUtility.UrlEncode(filename, System.Text.Encoding.UTF8) + ".xls");
Response.ContentEncoding = System.Text.Encoding.GetEncoding("big5");
Response.ContentType = "application/ms-excel";
th
<asp:ImageButton ID="btnDownLoad" runat="server" Height="16px"
ImageUrl="~/paReport/Images/sucaiwcom7804000eyu.gif"
οnclick="btnDownLoad_Click1" Width="16px" />
C#的下载到excel
string filename = "SSL_WIP_Data_" + DateTime.Now.ToString("yyyy-MM-dd");
Response.Clear();
Response.Buffer = true;
Response.Charset = "utf-8";
Response.AppendHeader("Content-Disposition", "attachment;filename=" + System.Web.HttpUtility.UrlEncode(filename, System.Text.Encoding.UTF8) + ".xls");
Response.ContentEncoding = System.Text.Encoding.GetEncoding("big5");
Response.ContentType = "application/ms-excel";
th