In the .NET Framework, there are several controls that list a number of links underneath the property list in the Properties window in the Visual Studio designer. (e.g. TabControl, ComboBox)
I have built a custom control, and I want to create a link on the Properties Window like the TabControl and ComboBox. When the link is clicked, a certain method on my control should be called.
How can I do this?
Thanks!
You need to create a custom designer for your control and override the
Verbsproperty. The first time your override is called, create aDesignerVerbCollectionand populate it. Return the collection on each subsequent call.Edit: By the way, you create the designer by deriving from
System.Windows.Forms.Design.ControlDesignerand you apply it to your class by putting this attribute on your class: