Click here to Skip to main content
13,452,262 members (52,500 online)
Click here to Skip to main content
Add your own
alternative version


63 bookmarked
Posted 4 Sep 2002

Advanced Shape Control

, 4 Sep 2002
Rate this:
Please Sign up or sign in to vote.
Advanced Shape Control


For some reason microsoft decided that we don't need the shape control that comes with Visual Studio 6.0, and removed it from VS.NET and left us to buy a third party control or develop one by our own.

Well, with the extensive namespaces that dot net supports for GDI+ and Windows Controls, it's easy to develop and extend the old shape control. The main purpose of this control is, its a lightweight control and  improves the user interface very much by grouping controls with out using a Group box or other controls.

This article is also a good resource for GDI+, and propertygrid control. I am developing this control as a Windows Extended controls library, to which i will be adding more controls in future. So, any suggetions for custom controls are welcome.

This article assumes that you have good understanding of GDI+, PropertyGrid and Windows Controls.

Refer to my other article on propertygrid Using PropertyGrid

NameSpaces Used 


Topics Covered 

  • GDI +
  • Windows Controls
  • PropertyGrid


The attached project has a demo showing how to use the control. Well, using the control is fairly simple yet very extensive. It supports 4 shapes with Solid colors, Gradiant fill, Textures, Hatch fills, shadows, 3D Borders,text and 3D border styles. Using these combinations you can create a variety of effects. The main purpose of this control is to improve the visual appearance of the forms, so use of 1 or 2 instances will be enough to achive the result.


Properties are divided into sub categories as 















Each of these properties can be expanded from propertygrid and customized based on the requirement also these properties can be turned on or off by a Drawxxxx property.   

ToDo Features

  • Implement support for other shapes
  • Implement a C# version
  • Implement 3D Borders for all shapes


  • Please post any remarks,bugs to this article's thread
  • Suggestions are welcome for windows controls as part of my Windows Extended Controls Library


This article has no explicit license attached to it but may contain usage terms in the article text or the download files themselves. If in doubt please contact the author via the discussion board below.

A list of licenses authors might use can be found here


About the Author

Sreenivas Vemulapalli
Web Developer
United States United States
Working as consultant in Client/server,Web Development, Automation areas using C#,Vb,,,Sql Server,Xml,Html&Dhtml etc..
Looking for a challenging project in .NET

You may also be interested in...


Comments and Discussions

GeneralMy vote of 5 Pin
manoj kumar choubey18-Feb-12 3:12
membermanoj kumar choubey18-Feb-12 3:12 
GeneralBadge Designer Pin Yogesh18-Aug-09 7:03 Yogesh18-Aug-09 7:03 
GeneralShare- RoundedRectangle not working Pin
sbkrishnan2511-Nov-08 22:38
membersbkrishnan2511-Nov-08 22:38 
Generalparameter is not valid.Error Pin
khandelwalpankajcdac13-Jan-08 5:28
memberkhandelwalpankajcdac13-Jan-08 5:28 
GeneralBorderStyle Bug Pin
MQUINNUSA18-Jun-07 11:09
memberMQUINNUSA18-Jun-07 11:09 
GeneralThanx ....Great control Pin
ammsamm21-Apr-07 13:05
memberammsamm21-Apr-07 13:05 
QuestionRead ShapeEx using xmlReader ?? Pin
Prajakta Patil16-Jan-07 17:46
memberPrajakta Patil16-Jan-07 17:46 
AnswerRe: Read ShapeEx using xmlReader ?? Pin Yogesh15-May-09 6:40 Yogesh15-May-09 6:40 
QuestionThanks! But we need your help... Pin
Prajakta Patil17-Dec-06 18:24
memberPrajakta Patil17-Dec-06 18:24 
GeneralDisplaying ShapeEx in my toolbox Pin
echelon38097-Dec-06 2:16
memberechelon38097-Dec-06 2:16 
GeneralRe: Displaying ShapeEx in my toolbox Pin
Edmondo Gigli5-Jan-10 1:00
memberEdmondo Gigli5-Jan-10 1:00 
GeneralGenerating Shapes at Runtime Pin
Chandan_Kr30-Aug-06 0:55
memberChandan_Kr30-Aug-06 0:55 
GeneralVB.NET 2003 Pin
fissidens4-Nov-05 23:26
memberfissidens4-Nov-05 23:26 
GeneralTransparent Fill Pin
muralikannur6-Mar-05 21:52
membermuralikannur6-Mar-05 21:52 
GeneralRe: Transparent Fill Pin
Mohan Patil11-Mar-07 18:48
memberMohan Patil11-Mar-07 18:48 
GeneralRe: Transparent Fill Pin
a_annunz20-Feb-08 5:11
membera_annunz20-Feb-08 5:11 
AnswerRe: Transparent Fill Pin
dcallaghan11-Dec-08 5:59
memberdcallaghan11-Dec-08 5:59 
GeneralSSL Pin
sunyz23-Dec-04 20:40
membersunyz23-Dec-04 20:40 
Generalneed line control Pin
njpost4123-Feb-04 10:34
membernjpost4123-Feb-04 10:34 
GeneralExcellent Control. Fill Color bug... Pin
Anonymous21-Nov-03 17:53
sussAnonymous21-Nov-03 17:53 
GeneralExpandableObjectConverter busted Pin
elitecommerceserver17-Sep-03 18:14
memberelitecommerceserver17-Sep-03 18:14 
GeneralRe: ExpandableObjectConverter busted Pin
Anonymous19-Jun-04 2:28
sussAnonymous19-Jun-04 2:28 
GeneralGood work Pin
Nishant S11-Sep-03 3:21
editorNishant S11-Sep-03 3:21 
GeneralThx...I was looking for this type of control Pin
WGenc4-Aug-03 10:23
memberWGenc4-Aug-03 10:23 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.

Permalink | Advertise | Privacy | Terms of Use | Mobile
Web02-2016 | 2.8.180318.3 | Last Updated 5 Sep 2002
Article Copyright 2002 by Sreenivas Vemulapalli
Everything else Copyright © CodeProject, 1999-2018
Layout: fixed | fluid