I want to display a progress bar while doing some work, but that would hang the UI and the progress bar won\'t update.
I have a WinForm ProgressForm with a Pro
Pro
For me the easiest way is definitely to use a BackgroundWorker, which is specifically designed for this kind of task. The ProgressChanged event is perfectly fitted to update a progress bar, without worrying about cross-thread calls
BackgroundWorker
ProgressChanged