Example #1
0
 private void BT_StopSim_Click(object sender, EventArgs e)
 {
     if (BGW_LifecycleDemo.WorkerSupportsCancellation == true)
     {
         // Cancel the asynchronous operation.
         BGW_LifecycleDemo.CancelAsync();
     }
 }
Example #2
0
 private void BT_StartSim_Click(object sender, EventArgs e)
 {
     if (BGW_LifecycleDemo.IsBusy != true)
     {
         // Start the asynchronous operation.
         BGW_LifecycleDemo.RunWorkerAsync();
     }
 }