Response.ClearContent(); Response.Output.Write("<tr><td></td><td></td><td></td><td></td><td colspan='2' align='center'><div align='center' style='text-align:center'>" + imagepath + "</div></td></tr>"); Response.AddHeader("content-disposition", "attachment; filename=" + strFileName); Response.AddHeader("content-disposition", "attachment;filename=" + strFileName); Response.ContentType = "application/excel"; System.IO.StringWriter sw = new System.IO.StringWriter(); HtmlTextWriter htw = new HtmlTextWriter(sw); dg.RenderControl(htw); Response.Write(sw.ToString()); Response.End();
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)