asp.net webform download excel

private void exportBinaryToExcel(byte[] bytes, string filename)
{
Response.AddHeader("Content-Disposition", "attachment; filename=" + filename);
Response.AddHeader("Content-Length", bytes.Length.ToString());
Response.ContentType = "application/octet-stream";
Response.BinaryWrite(bytes);
Response.Flush();
}
上一篇:在 Java 中不使用多余变量交换两个字符串


下一篇:小白日记46:kali渗透测试之Web渗透-SqlMap自动注入(四)-sqlmap参数详解- Enumeration,Brute force,UDF injection,File system,OS,Windows Registry,General,Miscellaneous