示例#1
0
        private void add_Click(object sender, EventArgs e)
        {
            MedicalCert medicalCert = _driver.createMedicalCert();

            MedicalCert_AddEdit medicalCertAE = new MedicalCert_AddEdit(medicalCert);
            if (medicalCertAE.ShowDialog() == System.Windows.Forms.DialogResult.OK)
                loadData();
        }
示例#2
0
        private void add_Click(object sender, EventArgs e)
        {
            MedicalCert medicalCert = _driver.createMedicalCert();

            MedicalCert_AddEdit medicalCertAE = new MedicalCert_AddEdit(medicalCert);

            if (medicalCertAE.ShowDialog() == System.Windows.Forms.DialogResult.OK)
            {
                loadData();
            }
        }
示例#3
0
        private void dgvMedicalCert_CellDoubleClick(object sender, DataGridViewCellEventArgs e)
        {
            if (isCellNoHeader(e.RowIndex))
            {
                int idMedicalCert = Convert.ToInt32(dgvMedicalCert.Rows[e.RowIndex].Cells[0].Value);

                MedicalCert medicalCert = _medicalCertList.getItem(idMedicalCert);

                if ((e.ColumnIndex == 1) && (medicalCert.File != string.Empty))
                {
                    tryOpenFile(medicalCert.File);
                }
                else
                {
                    MedicalCert_AddEdit medicalCertAE = new MedicalCert_AddEdit(medicalCert);
                    if (medicalCertAE.ShowDialog() == System.Windows.Forms.DialogResult.OK)
                        loadData();
                }
            }
        }
示例#4
0
        private void dgvMedicalCert_CellDoubleClick(object sender, DataGridViewCellEventArgs e)
        {
            if (isCellNoHeader(e.RowIndex))
            {
                int idMedicalCert = Convert.ToInt32(dgvMedicalCert.Rows[e.RowIndex].Cells[0].Value);

                MedicalCert medicalCert = _medicalCertList.getItem(idMedicalCert);

                if ((e.ColumnIndex == 1) && (medicalCert.File != string.Empty))
                {
                    tryOpenFile(medicalCert.File);
                }
                else
                {
                    MedicalCert_AddEdit medicalCertAE = new MedicalCert_AddEdit(medicalCert);
                    if (medicalCertAE.ShowDialog() == System.Windows.Forms.DialogResult.OK)
                    {
                        loadData();
                    }
                }
            }
        }