| anuj_87Response.Clear();
Response.Buffer = true;
Response.AddHeader("content-disposition",
"attachment; filename=" + Session["NwAccountName"] + "_" + DateTime.Now +
"_DestinationUrlsReport.xls");
Response.Charset = "";
Response.ContentType = "application/vnd.ms-excel";
var sw = new StringWriter();
var hw = new HtmlTextWriter(sw);
GridView1.AllowPaging = false;
GridView1.DataBind();
GridView1.RenderControl(hw);
Response.Output.Write(sw.ToString());
Response.Flush();
Response.End();