Beispiel #1
0
 //event delegate to subscibe to appMainService.ScanProgress event
 private void updateOnScanProgress(object sender, AppProgressEventArgs args)
 {
     Dispatcher.Invoke(() =>
     {
         TxtStatus.Text = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss") + ":" + args.ProgressMessage;
         if (args.MessageCode > 1)
         {
             TxtStatus.Background = Brushes.LightGoldenrodYellow;
         }
     });
 }
Beispiel #2
0
 //event delegate to subscibe to appMainService.ScanCancelled event
 private void updateOnScanCancelled(object sender, AppProgressEventArgs args)
 {
     Dispatcher.Invoke(() =>
     {
         TxtStatus.Text         = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss") + ":" + args.ProgressMessage;
         BtnSettings.IsEnabled  = true;
         BtnJob.IsEnabled       = true;
         BtnJobReload.IsEnabled = true;
         BtnStartStop.IsEnabled = true;
         BtnStartStop.Content   = "START";
         if (FormClosePending)
         {
             this.Close();
         }
     });
 }
Beispiel #3
0
 //event delegate to subscibe to appMainService.ScanCancelled event
 private void updateOnScanCancelled(object sender, AppProgressEventArgs args)
 {
     Dispatcher.Invoke(() => 
     {
         TxtStatus.Text = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss") + ":" + args.ProgressMessage;
         BtnSettings.IsEnabled = true;
         BtnJob.IsEnabled = true;
         BtnJobReload.IsEnabled = true;
         BtnStartStop.IsEnabled = true;
         BtnStartStop.Content = "START";
         if (FormClosePending) { this.Close(); }
     });
 }
Beispiel #4
0
 //event delegate to subscibe to appMainService.ScanProgress event
 private void updateOnScanProgress(object sender, AppProgressEventArgs args)
 {
     Dispatcher.Invoke(() =>
     {
         TxtStatus.Text = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss") + ":" + args.ProgressMessage;
         if (args.MessageCode > 1) { TxtStatus.Background = Brushes.LightGoldenrodYellow; }
     });
 }