protected void SortAndBindRecords(string sortCriteria) { string datasetSql = CacheManager.GetDatasetSQL(Session[SessionKey.DatasetId]); ReportDa da = new ReportDa(); DataTable sortdt = da.GetNeuroSpecimenMissingOR(datasetSql); string SortField; switch (sortCriteria) { case "PtName": SortField = "PtLastName"; SortData(sortdt, SortField); break; case "PtMRN": SortField = "PtMRN"; SortData(sortdt, SortField); break; case "AccessionDate": SortField = "AccessionDate"; SortData(sortdt, SortField); break; case "Disease": SortField = "Disease"; SortData(sortdt, SortField); break; case "Specimens": SortField = "Specimens"; SortData(sortdt, SortField); break; } reportResults.DataSource = sortdt.DefaultView; reportResults.DataBind(); }
override protected void Page_Load(object sender, System.EventArgs e) { datasetSql = CacheManager.GetDatasetSQL(Session[SessionKey.DatasetId]); ReportDa da = new ReportDa(); DataTable dt = da.GetNeuroSpecimenMissingOR(datasetSql); if (dt.Rows.Count > 0) { reportResults.DataSource = dt.DefaultView; reportResults.DataBind(); // log report view base.LogReportView(); resultMessage = "There are " + dt.Rows.Count + " missing Operating Room records for specimen patients"; } else { resultMessage = "There are no missing Operating Room records for specimen patients"; } }