473,413 Members | 1,778 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,413 software developers and data experts.

shaped bnt

i want to make a shaped bnt like star or circle something
like that .(with the full code)
Jul 21 '05 #1
2 1550
http://msdn.microsoft.com/library/de...us/gdicpp/GDIP
lus/UsingGDIPlus/FillingShapeswithaGradientBrush/CreatingaPathGradient.asp
"bershama" <th****@hotmail.com> wrote in message
news:02****************************@phx.gbl...
i want to make a shaped bnt like star or circle something
like that .(with the full code)

Jul 21 '05 #2
Bershama,
What do you mean by bnt?

Do you mean button?

Set the Control.Region property of your button to the shape you want. You
can use a GraphicsPath object to create the region.

I normally put the following code in both the constructor & the Resize event
(a subroutine called from both).

For an round button try something like:
m_path = New System.Drawing.Drawing2D.GraphicsPath()
m_path.AddEllipse(me.ClientRectangle)
Me.Region = New System.Draing.Region(m_path)

Then as William suggested you can use a PathGradientBrush to paint it.

Hope this helps
Jay

"bershama" <th****@hotmail.com> wrote in message
news:02****************************@phx.gbl...
i want to make a shaped bnt like star or circle something
like that .(with the full code)

Jul 21 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: skullcap | last post by:
Is there any way using HTML 4.01 of wrapping text and other inline elements into an 'L' or 'C' shaped space in a table - i.e. telling the browser that a series of table cells which don't form a...
5
by: vBOT | last post by:
Hi all, I have an odd shaped graphic I would like to use as my interface (see it here at http://www.mokee.com/vbot/ver3/face.jpg) The part I want to be transparent on the image is red. I set the...
3
by: James | last post by:
I have an picture cut out in a certain shape that I would like to make as my form. I have tried following the directions in MSDN on how to make shaped windows forms but their directions did not work...
2
by: Flix | last post by:
I need some help to handle the Region property of my Form in the correct way. Usually when I create shaped forms in my programs, I modify the Form.Region property, making it include only a part of...
4
by: Publicjoe | last post by:
Hi guys, I am writing an app that I wish to have a transparent background and hence a shaped form. In the InitializeComponent() method I set the members of the form to the following: //--...
4
by: Failure | last post by:
As far as I know, Groupboxes only come in one shape, a rectangle. But on one of my forms, it would be best if I could have a groupbox that's shaped like this: _______ | | _________|...
0
by: dr | last post by:
C# Irregular shaped user controls. How to make usercontrol have transparency key for its background image? I want to have irregular shaped user controls on my form. like a funny shaped button....
1
by: PankajGaur | last post by:
Hi, I need to create a Ellipse shaped user control which have folloiwng attributes: 1) The edges are smooth 2) The control shuld only be selected when click on the ellipse shape & not when...
0
by: =?Utf-8?B?UGFua2FqR2F1cg==?= | last post by:
Hi, I need to create a Ellipse shaped user control which have folloiwng attributes: 1) The edges are smooth 2) The control shuld only be selected when click on the ellipse shape & not when...
3
vdraceil
by: vdraceil | last post by:
Hi everyone,i just wanted to know whether it is possible to hav different shaped command buttons in VB6.0?-i mean using oval shaped buttons,star shaped buttons,something like that in my forms just to...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.