Getting the ProgressBar to Refresh

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

So, I have this For Each loop that takes a while to run. I wanted to take
advantage of the visual feedback the ProgressBar could give to the impatient
user. However, when I place the ProgressBar.Value=x and ProgressBar.Refresh
within the loop, I can't seem to get the ProgressBar to redraw itself to show
the progress in real time. Any suggestions?
 
application.doevents ?
or maybe you are after the Style.Marque property setting for progress bar ?
 
michael said:
So, I have this For Each loop that takes a while to run. I wanted to take
advantage of the visual feedback the ProgressBar could give to the
impatient
user. However, when I place the ProgressBar.Value=x and
ProgressBar.Refresh
within the loop, I can't seem to get the ProgressBar to redraw itself to
show
the progress in real time. Any suggestions?

Maybe you need an 'Application.DoEvents()' call.
 
Back
Top