User Controls not showing up in the toolbox

Viewed 104172

I have some UserControls that I created in ProjectA. I have ProjectB that has a windows form that I want to put the controls on. Both of these projects are in a single solution. There's a reference to ProjectA from ProjectB so it can "see" the UserControls.

However, the UserControls do not show up in the toolbox for me to drag to the windows form.

I've tried rebuilding. I've also deleted the 'bin' directory to force a rebuild-all.

How do I get VS2008 to populate the toolbox with my UserControls?

29 Answers

Check this setting:

Tools > Options > Windows Forms Designer > General : AutoToolboxPopulate

It should be set to True for this to work.

Another reason that user controls may not show up in the toolbox is if they do not have a default constructor.

Usually you need to build the solution. That almost always works for me.

Also double check that your user controls have a valid Namespace.

I just found that controls without namespace are not placed inside the ToolBox.

Related