title: How to pause execution for few seconds and continue the loop?
body: <p>I am creating a small applicaiton for simulating dice roll. To simulate bounces I change the position of the picture randomly. Now to simulate more than one bounce, I used a for loop to continuously change the position of the picture box. But it is not happening as I planned, the form only displays the position of the last loop. I even tried using <code>System.Threading.Thread.Sleep(1000)</code> hoping to show the bounces, but even they show the last loop only.</p>
  
  <pre><code>For bounceCount As Integer = 1 To bounces
      bounce(pb_dice1)
      bounce(pb_dice2)
      System.Threading.Thread.Sleep(3000) 'I need to pause here and show the recent change in position then continue after 3 seconds
  Next
  </code></pre>
  
  <p>the <code>bounce</code> method changes the position of the <code>PictureBox</code>.</p>
  
  <p>How can I pause my for loop, display the newly positioned dices, and then continue after 3 seconds?</p>