Пример #1
0
        private void tileTreatment_Click_1(object sender, EventArgs e)
        {
            addCT ct = new addCT();

            ct.id = dgv.CurrentRow.Cells[0].Value.ToString();
            ct.ShowDialog();
        }
Пример #2
0
        private void btnaddTreat_Click(object sender, EventArgs e)
        {
            addCT ct = new addCT();

            ct.id = dgv.CurrentRow.Cells["ID Number"].Value.ToString();
            ct.ShowDialog();
        }
Пример #3
0
        private void btnCT_Click(object sender, EventArgs e)
        {
            this.Close();
            addCT ct = new addCT();

            ct.id = lblID.Text;
            ct.ShowDialog();
        }
Пример #4
0
        void save()
        {
            try
            {
                if (txtBMI.Text == "" || txtWeight.Text == "" || txtPR.Text == "" || txtRR.Text == "" ||
                    txtRemarks.Text == "" || txtBP.Text == "" || txtTemp.Text == "" || txtPHname.Text == "")
                {
                    MetroMessageBox.Show(this, "Input required fields!", "Error", MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
                }
                else
                {
                    GetInputs();
                    //calling save method from controller
                    //backgroundWorker.RunWorkerAsync();
                    //p.ShowDialog();
                    if (pm.patientAdd(this))
                    {
                        MetroMessageBox.Show(this, "Saved Successfully", "Saved", MessageBoxButtons.OK, MessageBoxIcon.Information);
                        DialogResult res = MetroMessageBox.Show(this, "Add Treatment?", "Clinical and Treatment", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
                        if (res == DialogResult.Yes)
                        {
                            addCT ct = new addCT();
                            ct.id = pm.studentId;
                            ct.ShowDialog();
                        }
                    }


                    reset();
                    tbProfile.SelectedIndex = 0;
                }
            }
            catch (Exception ex)
            {
                MetroMessageBox.Show(this, "Error " + ex);
            }
        }