public void RemoveDr() { String text = "Do You Want To Remove " + ListSelectedDoctor.Value + " ?"; DialogResult answer = System.Windows.Forms.MessageBox.Show(text, "", MessageBoxButtons.YesNo, MessageBoxIcon.Question); if (answer == DialogResult.Yes) { DoctorsComboBox.Add(new ComboBoxPairs(ListSelectedDoctor.Key, ListSelectedDoctor.Value)); Hospital.Patients[PatientID].removeDoctor(ListSelectedDoctor.Key); ((Doctor)Hospital.Employees[ListSelectedDoctor.Key]).Patients.Remove(PatientID); HospitalDB.DeleteDoctorPatient(ListSelectedDoctor.Key, PatientID); DoctorsList.Remove(ListSelectedDoctor); DoctorsNumber = "Doctors: " + Hospital.Patients[PatientID].Doctors.Count().ToString(); } }