public void Reset() { noUpdate = true; this.Patient = new Patient(); txtHistory.Text = ""; txtName.Text = ""; txtPhone.Text = ""; txtMobile.Text = ""; txtEmail.Text = ""; txtAddress.Text = ""; txtZipCode.Text = ""; txtCity.Text = ""; txtCountry.Text = ""; dateTimeNextAppoint.Value = DateTime.Now; dateTimeNextAppoint.Checked = false; dateTimeAppointment.Value = DateTime.Now; listAppointment.Items.Clear(); btnEditVisit.Enabled = false; btnRemoveVisit.Enabled = false; this.listNotes.Clear(); this.listPhotos.Clear(); picPhoto.Image = Properties.Resources.Unknown_profile; noUpdate = false; }
public void Load_Patient(Patient patient) { Reset(); this.Patient = patient; FillFields(); }
public int Add(Patient p) { patients.Add(p); modified = true; int id = (patients.Count - 1); Console.WriteLine("Person ({1}) added to {0}", id.ToString(), p.Name); return id; }
public void Modify(int id, Patient p) { if (id >= patients.Count) { Console.WriteLine("Invalid id to replace patient! -> {0}", id.ToString()); return; } Console.WriteLine("Replacing {0} ({1})", id.ToString(), patients[id].Name); patients[id] = p; modified = true; }