private void bw8_RunWorkerCompleted(Object sender, RunWorkerCompletedEventArgs e) { if (e.Error != null) { ResultBox8.AppendText("BW stopped. Errors occured." + Environment.NewLine); ResultBox8.AppendText(e.Result.ToString() + "" + Environment.NewLine); totalErrors8++; } else { if (e.Cancelled) { ResultBox8.AppendText("Cancelled by user." + Environment.NewLine); totalErrors8++; } else { WorkResult result = e.Result as WorkResult; ResultBox8.AppendText(result.ToString() + Environment.NewLine); totalErrors8 += result.errors(); } } Start8.Enabled = true; }
private void bw8_ProgressChanged(object sender, ProgressChangedEventArgs e) { this.progressBar8.Value = e.ProgressPercentage; string reportmsg = e.UserState as String; ResultBox8.AppendText(reportmsg + Environment.NewLine); }
private void Start8_Click(object sender, EventArgs e) { Start8.Enabled = false; totalErrors8 = 0; if (bw8.IsBusy != true) { bw8.RunWorkerAsync(); ResultBox8.AppendText("Running..." + Environment.NewLine); } }