protected override void OnDoWork(DoWorkEventArgs e) { ReportProgress(0, SortingState.Start); TableController tableController = new TableController(); AudioFileInfo audioFile = new AudioFileInfo(); tableController.InsertInitialize(); while (FileListEnumerator.MoveNext()) { if (CancellationPending) { e.Cancel = true; break; } FileInfo currentFile = new FileInfo(FileListEnumerator.Key.ToString()); audioFile.GetInfo(currentFile); tableController.Insert(currentFile, audioFile); } ReportProgress(100, "Done!"); e.Result = SortingState.Completed; }