VB.NET Knob Control using Windows Forms and GDI+






4.72/5 (16 votes)
Jul 12, 2002

151065

4585
User Drawn Control for .NET Winforms using GDI+
This code was originally written by Jigar Desai using C#
. Naturally, as a VB Programmer, I needed to see if
this control could be readily implemented using VB.NET
. After many hours of hair pulling, this control has been
successfully ported to VB.NET
. Additionally, I added a new design-time property to the original control
which allows the Knob Color to take on a different color than the
control's background. The only change
to the original code is the addition of the "KnobColor" Property. I have included the "TestKnobControl" Project to demonstate the use of this control's ValueChanged Event
as well as the vast array of different colors now available for the control.
This control implements several interesting techniques, to include: Delegates
, Properties
, GDI+
and Overriding
base methods. Special thanks, from the
VB Community, to Jigar
for his quick and positive response on my request to post this control in VB.NET
.
The original Article for this control can be found on C-SharpCorner.com