protected void grdSankeyHistory_RowCommand(object sender, GridViewCommandEventArgs e) { if (e.CommandName == "view") { LinkButton lnkView = (LinkButton)e.CommandSource; string job_id = lnkView.CommandArgument; //Response.Redirect("frmCircularSankeyLP.aspx?job_id=" + job_id + "&&ID=" + job_id); Response.Redirect("frmCircularSankey.aspx?job_id=" + job_id); } if (e.CommandName == "Delete") { LinkButton lnkView = (LinkButton)e.CommandSource; string job_id = lnkView.CommandArgument; objDataHandling.DeleteData(job_id); objDataHandling.showData(grdSankeyHistory); string script = "alert('" + "Data has been deleted successfully" + "');"; ScriptManager.RegisterStartupScript(this, typeof(Page), "UserSecurity", script, true); } }