private void btnFindTests_Click(object sender, RoutedEventArgs e) { try { List <BE.Test> found = bl.getAlltestsInDate(DateTime.Today); foreach (BE.Test item in found) { MessageBox.Show(item.ToString()); } ; } catch (Exception ex) { MessageBox.Show(ex.Message); } }