private void DisplayTreatment()
 {
     dgvPatientProperties.Columns.Add("cName", "Name");
     dgvPatientProperties.Columns.Add("cDateStarted", "Date Started");
     dgvPatientProperties.Columns.Add("cDateEnded", "Date Ended");
     patientTreatment = database.getPatientTreatment(patient);
     patientTreatment.ForEach(pt => dgvPatientProperties.Rows.Add(pt.Treatment.Name, pt.Start_Date.ToShortDateString(), getEndDateDisplay(pt.End_Date)));
     btnViewDetails.Text = "View Treatment Details";
 }
        private void loadTreatment(TreeView tvMedicalData)
        {
            tvMedicalData.Nodes.Add("Treatment");
            tvMedicalData.Nodes[tvMedicalData.Nodes.Count - 1].ImageIndex         = 6;
            tvMedicalData.Nodes[tvMedicalData.Nodes.Count - 1].SelectedImageIndex = 6;

            List <PatientTreatment> patientTreatment = database.getPatientTreatment(patient).OrderBy(pt => pt.Date_Received).ToList();

            foreach (PatientTreatment pt in patientTreatment)
            {
                tvMedicalData.Nodes[tvMedicalData.Nodes.Count - 1].Nodes.Add(
                    pt.Treatment.Name + " - " + pt.Date_Received);
                tvMedicalData.Nodes[tvMedicalData.Nodes.Count - 1].LastNode.ImageIndex         = 6;
                tvMedicalData.Nodes[tvMedicalData.Nodes.Count - 1].LastNode.SelectedImageIndex = 6;
            }
        }