private void BindGrid() { string id = string.Format("Id: {0} Uri: {1}", Guid.NewGuid(), HttpContext.Current.Request.Url); using (Utils utility = new Utils()) { utility.MethodStart(id, System.Reflection.MethodBase.GetCurrentMethod()); } _reportBO = new Bill_Sys_ReportBO(); try { //if (extddlLocation.Visible == true && extddlLocation.Text != "NA") //{ // grdAllReports.DataSource = _reportBO.GetAllReports("SP_REPORT_GET_PAYMENTS", txtFromDate.Text, txtToDate.Text, txtCompanyID.Text, extddlLocation.Text); // grdAllReports.DataBind(); // grdForReport.DataSource = _reportBO.GetAllReports("SP_REPORT_GET_PAYMENTS", txtFromDate.Text, txtToDate.Text, txtCompanyID.Text, extddlLocation.Text); // grdForReport.DataBind(); //} //else //{ // grdAllReports.DataSource = _reportBO.GetAllReports("SP_REPORT_GET_PAYMENTS", txtFromDate.Text, txtToDate.Text, txtCompanyID.Text); // grdAllReports.DataBind(); // grdForReport.DataSource = _reportBO.GetAllReports("SP_REPORT_GET_PAYMENTS", txtFromDate.Text, txtToDate.Text, txtCompanyID.Text); // grdForReport.DataBind(); //} if (extddlCaseType.Text != "NA") { grdAllReports.DataSource = _reportBO.GetAllReportsCase("SP_REPORT_GET_PAYMENTS", txtFromDate.Text, txtToDate.Text, txtCompanyID.Text, extddlCaseType.Text); grdAllReports.DataBind(); grdForReport.DataSource = _reportBO.GetAllReportsCase("SP_REPORT_GET_PAYMENTS", txtFromDate.Text, txtToDate.Text, txtCompanyID.Text, extddlCaseType.Text); grdForReport.DataBind(); } else { grdAllReports.DataSource = _reportBO.GetAllReportsCase("SP_REPORT_GET_PAYMENTS", txtFromDate.Text, txtToDate.Text, txtCompanyID.Text, extddlCaseType.Text); grdAllReports.DataBind(); grdForReport.DataSource = _reportBO.GetAllReportsCase("SP_REPORT_GET_PAYMENTS", txtFromDate.Text, txtToDate.Text, txtCompanyID.Text, extddlCaseType.Text); grdForReport.DataBind(); } } catch (Exception ex) { Elmah.ErrorSignal.FromCurrentContext().Raise(ex); using (Utils utility = new Utils()) { utility.MethodEnd(id, System.Reflection.MethodBase.GetCurrentMethod()); } string str2 = "Error Request=" + id + ".Please share with Technical support."; base.Response.Redirect("Bill_Sys_ErrorPage.aspx?ErrMsg=" + str2); } //Method End using (Utils utility = new Utils()) { utility.MethodEnd(id, System.Reflection.MethodBase.GetCurrentMethod()); } }