Question

I have a DatePicker custom control that I am trying to add to toolbox. The name of the file is BasicFrame.WebControls.BasicDatePicker.dll and I go through the procedure of right click in Toolbox > Choose Items and then selecting the file after browsing to it under .NET Framework components.

I however get this error message:

There are no components in that can be placed on toolbox

Why do I get this message and how can I resolve it?

Was it helpful?

Solution 2

Have you checked the visibility of the custom classes?

If you haven't declared them as public they will default to internal and hence aren't exposed to Visual Studio for use.

OTHER TIPS

In some cases you can solve this problem with drag and drop:

  • open Windows explorer and navigate to the DLL
  • drag the DLL and drop it on Visual Studio in the Toolbox, exactly where you want your components to appear

Sometimes drag and drop does not work also. In this case you can

  • open Windows explorer and navigate to the DLL
  • copy the dll file and paste it directly on the toolbox tab you wish to place the controls.

Visual Studio 2019 - unable to get VS2019 to recognise a simple user control. I found this was caused by having no parameter-less constructor in the control. As soon as I ensured there was a ctor with no parameters, the control was recognised. I found I was able to use constructor chaining/overloading. Hopefully this will help others having this issue.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top