Пример #1
0
 private void MnuInsert_Click(object sender, EventArgs e)
 {
     try
     {
         frmPerssonelMain frm = new frmPerssonelMain();
         if (frm.ShowDialog() == DialogResult.OK)
         {
             LoadData();
         }
     }
     catch (Exception ex)
     {
         frmMessage f = new frmMessage(EnumMessageFlag.ShowFlag, Color.Red, ex.Message);
         f.ShowDialog();
     }
 }
Пример #2
0
 private void MnuEdit_Click(object sender, EventArgs e)
 {
     try
     {
         if (DGrid.RowCount == 0)
         {
             return;
         }
         Guid _guid = (Guid)DGrid[dgGuid.Index, DGrid.CurrentRow.Index].Value;
         var  frm   = new frmPerssonelMain(_guid, true);
         if (frm.ShowDialog() == DialogResult.OK)
         {
             LoadData();
         }
     }
     catch (Exception exception)
     {
         frmMessage frm = new frmMessage(EnumMessageFlag.ShowFlag, Color.Red, exception.Message);
         frm.ShowDialog();
     }
 }