private void btnAdd_Click(object sender, EventArgs e)
        {
            frmAddEditApplicant frm = new frmAddEditApplicant();

            DatabaseConnection.adding   = true;
            DatabaseConnection.updating = false;
            if (frm.ShowDialog() == DialogResult.OK)
            {
                LoadData();
            }
        }
Ejemplo n.º 2
0
        private void btnView_Click(object sender, EventArgs e)
        {
            frmAddEditApplicant frm = new frmAddEditApplicant();

            DatabaseConnection.adding   = true;
            DatabaseConnection.updating = false;
            if (frm.ShowDialog() == DialogResult.OK)
            {
                string       count = (Int32.Parse(lvwApp.Items.Count.ToString()) + 1).ToString();
                ListViewItem lv    = new ListViewItem(DatabaseConnection.appID);
                lv.SubItems.Add(count);
                lv.SubItems.Add(DatabaseConnection.applName);
                lv.SubItems.Add(DatabaseConnection.appfName);
                lv.SubItems.Add(DatabaseConnection.appMI);
                lv.SubItems.Add(DatabaseConnection.appAdd);
                lvwApp.Items.Add(lv);
            }
        }