2

For the default ProgressBar control, when the value is less than the max value, there is a glow effect (white part in bottom progress bar). Is there a simple way to disable the glow?

enter image description here

user3600400
  • 183
  • 1
  • 2
  • 10
  • You could mess around with [ProgressBarRenderer](http://msdn.microsoft.com/en-us/library/system.windows.forms.progressbarrenderer.aspx) - there's an example for a vertical bar on that page, I'm sure you could alter it for your purposes. Not exactly "simple", though. There isn't a "change this property" solution, afaik. – Blorgbeard Jul 21 '14 at 02:04
  • Thanks @GrantWinney - is there any way to change the colour of the paused progressbar from yellow to green? – user3600400 Jul 21 '14 at 02:26
  • The last time I checked the consense was: Write your own! – TaW Jul 21 '14 at 06:58
  • It is not a "glow effect", it is an *animation*. Moves from left to right, tells the user that your program is not hung-up. So, your program is probably hung-up. Don't shoot the messenger, fix the problem. – Hans Passant Jul 21 '14 at 22:05
  • Possible duplicate of [Windows Forms ProgressBar: Easiest way to start/stop marquee?](https://stackoverflow.com/questions/312936/windows-forms-progressbar-easiest-way-to-start-stop-marquee) – Jim Fell Jul 10 '18 at 14:54

2 Answers2

1
  1. Set the ProgressBar.Minimum to what will be progress bar's value.
  2. Set the ProgressBar.Value to equal the ProgressBar.Minimum.
  3. Set the ProgressBar.Minimum to zero. Presto - no glow.

Works on toolstrip progress bars. 'Don't know about Forms.ProgressBar but seems like it should.

  • Wow, this actually does work! I wouldn't suggest relying on what I assume is undocumented behavior, but what a convenient hack! – A C Jul 09 '21 at 04:23
0

In case anyone was wondering, I solved this by using the custom progress bar class in the second answer here. The custom progress bar doesn't have a glow effect, and it also has the feature of allowing custom text on the progress bar. I also used the third answer ("Avoid flickering text") to solve the flicker problem.

Community
  • 1
  • 1
user3600400
  • 183
  • 1
  • 2
  • 10