private void btnAddNew_Click(object sender, EventArgs e)
 {
     try
     {
         btnAddNew.UseSelectable = false;
         using (adduser = new FormAddUser())
         {
             adduser.ShowDialog();
         }
     }
     catch (Exception ex)
     {
         MessageBox.Show(ex.ToString(), "Error", MessageBoxButtons.OKCancel, MessageBoxIcon.Error);
         GC.Collect();
     }
     finally
     {
         using (TBL_USER_DATA_ACCESS uda = new TBL_USER_DATA_ACCESS())
         {
             dataGridViewUser.DataSource = uda.ShowUserAllIncludeInActive();
         }
         GC.Collect();
     }
     btnAddNew.UseSelectable = false;
 }
Example #2
0
        private void addBtn_Click(object sender, EventArgs e)
        {
            FormAddUser newAddForm = new FormAddUser();

            newAddForm.AddFinished += AddFinsh;
            newAddForm.ShowDialog();
        }
Example #3
0
        private void modBtn_Click(object sender, EventArgs e)
        {
            if (userDataList.Rows.Count <= 0)
            {
                return;
            }
            FormAddUser newAddForm = new FormAddUser();

            newAddForm.ModFinished += ModFinsh;
            newAddForm.InitFormInfo((UserInfo)userDataList.SelectedRows[0].Tag);
            newAddForm.ShowDialog();
        }
Example #4
0
        private void gunaButtonAdd_Click(object sender, EventArgs e)
        {
            Form AddUser = new FormAddUser(btnRefresh);

            AddUser.ShowDialog();
        }