private void SwapToDetailed() { DataTable tbl; tbl = dataBaseHandler.GetPossibleCourses(1); List <int> ids = new List <int>(); foreach (DataRow row in tbl.Rows) { ids.Add(Convert.ToInt32(row[1])); } var results = from myRow in tbl.AsEnumerable() where ids.Contains(myRow.Field <int>("PossibleCourseID")) select myRow; GrdReport.ItemsSource = results; }
private void SwapToDetailed() { GrdReport.ItemsSource = dataBaseHandler.GetPossibleCourses(scheduleID).AsDataView(); }