i am creating an excel file generate on button click.but after button click their is no display on popup box.
i think jquery file conflict..but their is no jquery file is calling or adding.
this is my code ..
protected void btnGenerate_Click(object sender, EventArgs e)
{
DataTable dt = new DataTable();
gvd_details.DataSource = ex.Getadmindtals(name.SelectedValue);
gvd_details.DataBind();
GridView gv = new GridView();
gv.DataSource = gvd_details.DataSource;
gv.DataBind();
Response.Clear();
Response.AddHeader("content-disposition", "attachment;filename=Details.xls");
string path = Server.MapPath("files\\");
Response.ContentType = "application/vnd.ms-excel";
Response.AppendHeader("content-disposition", "attachment;filename=Details.xls");
StringWriter sw = new StringWriter();
HtmlTextWriter hw = new HtmlTextWriter(sw);
gv.RenderControl(hw);
Response.Output.Write(sw.ToString());
Response.End();
}
plz help me..!! thnkx in adv..


Thiyagarajan ERank #2,329 · 607 reputationPosted Nov 23, 2018, 9:42 PM EST
Reylin MathewRank #4,152 · 361 reputationPosted Nov 23, 2018, 11:43 PM EST
Suraj KumarRank #353 · 7.1K reputationPosted Dec 12, 2018, 1:34 AM EST
Philip Lee6 reputationPosted Jan 15, 2019, 8:56 AM EST