private void onDATExited(object sender, Business.DAT.ExitedEventArgs e) { Business.DAT dat = sender as Business.DAT; dat.Exited -= onDATExited; if (e.HasError) { throw new Exception(e.Error); } string output = e.Output; if (!string.IsNullOrEmpty(output)) { var root = Business.LZSSFileMapParser.Parse(output); if (root != null) { this.rootSource.Add(root); this.NotifyPropertyChanged("RootSource"); } } }
public FileMapManagerViewModel() { Business.DAT dat = new Business.DAT(); dat.Exited += onDATExited; dat.Call(); }