Exemple #1
0
 private void cmdExitApp_Click(object sender, RoutedEventArgs e)
 {
     System.Threading.Thread vThread = new System.Threading.Thread(() =>
     {
         try
         {
             MTSynData.doSyncPost();
         }
         catch { }
     });
     vThread.Start();
     this.Close();
 }
Exemple #2
0
 private void grdPhieuThuCT_PreviewKeyDown(object sender, PreviewKeyDownEventArgs e)
 {
     if (e.KeyCode == Keys.F2)
     {
         fdoAdd();
     }
     else if (e.KeyCode == Keys.F3)
     {
         fdoEdit();
     }
     else if (e.KeyCode == Keys.F4)
     {
         fdoDel();
     }
     else if (e.KeyCode == Keys.F5)
     {
         fdoSave();
     }
     else if (e.KeyCode == Keys.F7)
     {
         if (pPhieuTCID == "")
         {
             Utils.showMessage("Bạn chưa chọn phiếu để in...", "Lưu ý");
         }
         new MTReport().rptTC_Phieuthu(pPhieuTCID);
     }
     else if (e.KeyCode == Keys.F8)
     {
         System.Threading.Thread vThread = new System.Threading.Thread(() =>
         {
             try
             {
                 MTSynData.doSyncPost();
             }
             catch { }
         });
         vThread.Start();
         this.Close();
     }
     else if (e.KeyCode == Keys.Escape)
     {
         BindData();
         setReadOnly(true);
         MTGlobal.SetToolStripButtonAction(pACT_ROLE, MTButton, "ABORT");
     }
 }
Exemple #3
0
 private void oWorker_DoWork(object sender, DoWorkEventArgs e)
 {
     MTSynData.doSyncPost();
 }