private void viewdata() { try { dt = new DataTable(); objbe.Action = "R"; dt = objm.Company_IUDR(objbe, conkey); GridView1.DataSource = dt; GridView1.DataBind(); } catch (Exception ex) { ExceptionLogging.SendExcepToDB(ex, Session["UsrName"].ToString(), Request.ServerVariables["REMOTE_ADDR"].ToString()); Response.Redirect("~/Error.aspx"); } }