protected override void OnDataSet()
        {
            if (!Objectbase.IsNullOrEmpty(this.mOpdTreatmentProcedure))
            {
                this.mOpdTreatmentProcedure.OPDTreatmentDate = this.dptTreatmentDate.Value;
                // treatment

                this.mPatient.OPDTreatmentProcedure = this.mOpdTreatmentProcedure;
                this.mOpdTreatmentProcedure.OPDTreatments.Clear();

                for (int i = 0; i < cmbTreatment.Items.Count; i++)
                {
                    if (cmbTreatment.GetItemChecked(i))
                    {
                        obj = new OPDTreatmentProcedureTreatment();
                        Guid gd = new Guid(cmbTreatment.Items[i].ToString());
                        obj.PatientGuid   = this.mPatient.ObjectGuid;
                        obj.TreatmentGuid = gd;
                        this.mOpdTreatmentProcedure.OPDTreatments.Add(obj);
                    }
                }

                for (int i = 0; i < cmbTreatment.Items.Count; i++)
                {
                    if (cmbTreatment.GetItemChecked(i))
                    {
                        cmbTreatment.SetItemChecked(i, false);
                    }
                }
            }
        }
        private OPDTreatmentProcedure GetSelectedProcedure(DataGridView dgv)
        {
            OPDTreatmentProcedure obj = null;

            if (dgv != null && dgv.CurrentRow != null)
            {
                obj = dgv.CurrentRow.Tag as OPDTreatmentProcedure;
            }
            return(obj);
        }