Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How do I add a user control to toolbox?

I want to create a CustomControl in toolbox in my C# application

like image 549
Stijn Leenknegt Avatar asked Dec 30 '10 17:12

Stijn Leenknegt


People also ask

How do I add components to my toolbox?

Right-click in the Toolbox, and from the pop-up menu choose Customize Toolbox, Add/Remove Items, or Choose Items (depending on the version of Visual Studio). In the Customize Toolbox dialog, click the . NET Framework Components tab.

How do I add controls to my panel?

To create a group of controlsDrag a Panel control from the Windows Forms tab of the Toolbox onto a form. Add other controls to the panel, drawing each inside the panel.


1 Answers

If your component is within the project, you can have them automatically added to the toolbox. Go to: Tools -> Options -> Windows Forms Designer and enable the "AutoToolboxPopulate" option.

If it's in a separate solution, you can build the control library, and drag and drop on the toolbox to add the components.

like image 136
Rowland Shaw Avatar answered Oct 02 '22 00:10

Rowland Shaw