please give me a appropriate example.
How to work with Progress Bar in winforms
I want to use progress bar and changed its value when events are running . How to working with progress bar in such situation.
I would like to use a BackgroundWorker. Because we have a loop that large in your WinForm it will block and your app will look like it has hanged.Now we are using BackgroundWorker.ReportProgress() to see how to report progress back to the UI thread and progress bar has been changed.
Output:
you can also set the property of Progress bar, such like this:
progressbar1.Minimum=0;
progressbar1.Minimum=100; etc.