EDIT:
Ok guys, the next version has been released and is available from the same download link as before. I am looking for an actual name to call this rather than just progress bar. So go ahead and feed them to me.
END EDIT
I whipped this up late last night, so it isn't perfect. I am sure there are many ways to shorten the code and I bet it can be made better, but for now I'll leave it as is. I am going to add the ability to change the font of the percentage, but that will come later.
I've never even so much as drawn with an API before so this was completely new to me. Also I've never made a usercontrol, but this was some good experience.
Version: 1.0.1
Features:
Update Log:Code:Able to set the background color (using 2 colors) Able to set the fill color (using 2 colors) Able to enable, disable gradients Able to change font color Able to disable percentage Able to add a drop shadow Able to set border color Min and Max values.
Benchmark TestsCode:'|||||||||||||||||||||||||||||||||||||||||||||||| '| UPDATE LOG | '| times are all central time (GMT -6) | '| | '| June 8, 2008 - 11:30PM | '| - Work Begins | '| | '| June 10, 2008 - 11:10PM | '| - stream-lined code | '| removed many unnecessary | '| calculations and calls. | '| - added Min and Max value | '| | '||||||||||||||||||||||||||||||||||||||||||||||||
Code:Tested at 10000 loops Microsoft Common Controls: 812ms ProgressBar Control V 1.0.0: 5250ms | 84.5% less efficient at 10000 loops ProgressBar Control V 1.0.1: 4688ms | 82.7% less efficient at 10000 loops
Pictures:
![]()







Reply With Quote