void doit_DoCompleted(object sender, DoCompletedEventArgs e) { if (e.Result != null) { MessageBox.Show(e.Result, "Error", MessageBoxButton.OK); return; } this.DialogResult = true; }
void _service_DoCompleted(object sender, DoCompletedEventArgs e) { this.No = e.Result; if (null != ServiceDoCompletedEvent) { ServiceDoCompletedEvent(this, e); } Container._Service.DoCompleted -= _service_DoCompleted; }