Question ProgressBar Problem

capedech

Well-known member
Joined
Oct 29, 2008
Messages
62
Programming Experience
Beginner
Hi,
I want to make a ProgressBar with text inside it and I want to make the ProgressBar not using bars.
Sample in the picture :
progressbar1.png


I can make the text inside the ProgressBar with CreateGraphics and DrawString, but I still can't make the progressbar not using bars.

Please help me.

Thanks in Advance.

Regards,
 

capedech

Well-known member
Joined
Oct 29, 2008
Messages
62
Programming Experience
Beginner
Hello.
I'd suggest to write your own control for this, since the bars should be a 'feature' of the Windows XP style.

Bobby
Hi Bobby, thanks for answering.
I'm sorry I'm still newbie, so in XP we can't do it ?
Could u explain more about it?

When u said to write myown control, do u mean to use picturebar ?

Thank you very much.
 

Robert_Zenz

Well-known member
Joined
Jun 3, 2008
Messages
503
Location
Vienna, Austria
Programming Experience
3-5
The XP Progressbar has this bars, at least as far as I know it. The Vista and Win9x progressbars don't have them. This is just a part of the style as in the Human (GTK+) theme the bars are animated.

With own control I had a UserControl in mind, in which you directly overwrite the OnPaint method, and paint your own progressbar 'from scratch' if you will. This will give you the freedom to decide how it should look like.

Bobby
 

Arijit

Member
Joined
Jun 20, 2009
Messages
10
Programming Experience
1-3
you know you can use an existing object just to show a value right? since a progressbar really doesn't have any extra properties... for example, you could use a scrollbar instead or you can make your own control as suggested above... personally, i use other controls to display progress because even I dont like those bars, even changing the progressbar's property of style to continuous doesn't work...

you know there's one thing u could do, u can disable visualxpstyle and then the progressbar appears continuous and the back color and fore color properties are shown too... the style has a classic look though, could you please tell me how to embed text into a progressbar though? like in a web browser, the progressbar has the status text in it...? :confused:
 

capedech

Well-known member
Joined
Oct 29, 2008
Messages
62
Programming Experience
Beginner
Yes, i am thinking to use picture box to make it looks like in the picture that I attached.
I am not a very pro programmer right now, so I really can't make my own control.
Can u show me some simple code? Or is there any link for me to learn to make my own control? Especially progressbar.

Thanks in Advance.

Regards,
 

Arijit

Member
Joined
Jun 20, 2009
Messages
10
Programming Experience
1-3

Latest posts

Top Bottom