Esempio n. 1
0
        private void Add_Button_Click(object sender, RoutedEventArgs e)
        {
            MessageBoxResult result = MessageBox.Show("Are you already a client?", "Add Box", MessageBoxButton.YesNoCancel);

            switch (result)
            {
            case MessageBoxResult.Yes:
                AddEditVisit win1 = new AddEditVisit((IAddEditVisitParent)this, (List <PATIENT>)service.getPatients(), (List <DOCTOR>)service.getDoctors());
                win1.ShowDialog();
                break;

            case MessageBoxResult.No:
                AddEditPatient win2 = new AddEditPatient(this);
                win2.ShowDialog();
                break;

            case MessageBoxResult.Cancel:
                break;
            }
        }
Esempio n. 2
0
 private void LoadData()
 {
     patients = new ObservableCollection <PATIENT>(service.getPatients());
     PatientDataGrid.ItemsSource = service.getPatients();
 }