Link to home
Start Free TrialLog in
Avatar of yaronusa
yaronusa

asked on

How to convert inherited control into DLL in c# csharp .net

I have several inherited controls (text boxes, combo boxes) which I can drag from the tool box and drop on the form.

But I would like to make them into DLL's, so that I can use them in various future projects? How do I do that?

Thanks!
SOLUTION
Avatar of Anurag Thakur
Anurag Thakur
Flag of India image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of yaronusa
yaronusa

ASKER

So I started a class library project, and added all the files to it, but I am having a problem with the following using statement on all the inherited controls:

using System.Windows.Forms;

Windows is underlined, and cannot be found, even with the intellisense.

Am I on the right track?

What will the reference to this class library project be? The namespace of my class library is CustomTextBoxes and the project name is TextBoxes.

Thank for your help I really appreciate it.
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Alright...
 
 I added the reference System.Windows.Forms to the TextBoxes project and the Windows is no longer underlined.
 To compile the Class Library project, I created an executable project.
 
 Then I created a new Windows Application called TestDriveTextBoxes project, and I added a reference to the TextBoxes.dll that was generated. But none of my inherited controls have shown in the toolbox anywhere.
 
 So I went back to the TestDriveTextBoxes project and in the toolbox, under the category 'TextBoxes Components' it says "There are no usable controls in this group. Drag an item onto this text to add it to the toolbox." So I try to do that, but it can't go on there.

Do you know why the inherited controls are not showing?
ASKER CERTIFIED SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial