Exemplo n.º 1
0
 private void btnNew_Click(object sender, EventArgs e)
 {
     try
     {
         frmServiceModuleEntry fSM = new frmServiceModuleEntry((int)Constant.Mode.Insert, 0);
         fSM.ShowInTaskbar = false;
         fSM.ShowDialog();
         LoadList();
         btnClear_Click(sender, e);
     }
     catch (Exception exc)
     {
         Utill.Common.ExceptionLogger.writeException("Service Module", exc.StackTrace);
         MessageBox.Show(Utill.Common.CommonMessage.ExceptionMesg, "Exception");
     }
 }
Exemplo n.º 2
0
 private void btnEdit_Click(object sender, EventArgs e)
 {
     try
     {
         if (dgvServiceModule.CurrentRow != null)
         {
             if (dgvServiceModule.SortedColumn != null)
             {
                 sortedColumn  = dgvServiceModule.SortedColumn;
                 sortDirection = dgvServiceModule.SortOrder;
             }
             frmServiceModuleEntry fSM = new frmServiceModuleEntry((int)Constant.Mode.Modify, (Int64)dgvServiceModule.CurrentRow.Cells["ServiceId"].Value);
             fSM.ShowInTaskbar = false;
             fSM.ShowDialog();
             setDefaultGridRecords(sender, e);
         }
     }
     catch (Exception exc)
     {
         Utill.Common.ExceptionLogger.writeException("Service Module", exc.StackTrace);
         MessageBox.Show(Utill.Common.CommonMessage.ExceptionMesg, "Exception");
     }
 }