There are 2 ways to use a progress bar:
One is to manage it yourself performing steps when you want the bar to increase:
progressBar1.PerformStep();
Using this you will need to calculate the number of steps you want and when you want them to show in the code. so if you have 2 steps you will set the progresbar to have 3 steps and after each step call the code above.
The second way is to use a timer. Here you set the timer interval to whatever time you want your step to move and call the perform step on the timer.tick event. When you start your process you also start the timer to enable the progressbar. On load the timer needs to be disabled and you will have something like this:
timer1.enabled=true;
timer1.enabled=false