title: How to refresh ProgressBar accurately
body: <p>I wrote a short method that uses a for loop 2 times:</p>
  
  <pre><code>progressBar1.Minimum = 1;
  progressBar1.Maximum = 1000000;
  progressBar1.Step = 1;
  
  for (int idx = 1; idx &lt; 1000000; idx++)
  {    
      progressBar1.PerformStep();
  }
  
  Thread.Sleep(2000);
  progressBar1.Invalidate();
  this.Update();
  
  progressBar1.Value = 1;
  for (int idx = 1; idx &lt; 1000000; idx++)
  {
      progressBar1.PerformStep();
  }
  </code></pre>
  
  <p>My question is this: on the 1st pass, when the value gets to 1000000 the actual colored bar only
  displays about 50-75% across, but never 100% across, even though the value has reached the maximum.</p>
  
  <p>This is unique to using the progressbar multiple times in one method.</p>
  
  <p>How can I get the actual colored bar to get to the very end?</p>
  
  <p>(Apparently its a buffering thing?)</p>