C
crowl
VS.2003, .NET Framework 1.1, C#
My goal: Creating a dll (helper.dll) which contains some UserControls
and some other helpful classes in order to use it in other projects.
Symtoms: The inital use of the UserControl component works. However, if
the Helper Project is recompiled, the UserControl does not work
correctly anymore in the other projects. Furthermore, the previously
visible User Control may not be visible in the Windows Form Designer.
Here the steps I have done:
1) Created a new Project (Helper Project)
2) Added some classes and a UserControl (there are some textboxes,
dropdown boxes, etc.)
Remark: UserControl (ctlHelper.cs)
public class ctlHelper : System.Windows.Forms.UserControl
3) Compiled the procject.
Now the next steps are including the dll in the desire project.
1) Created a new Project
2) Added a new reference to the helper.dll
3) Add -> Add Inherited Control -> Inherited User Control -> Browse to
the helper.dll location -> OK
Now the designed UserControl appears in the Toolbox of VS.2003 under
"My User Controls"
4) Drag & Drop the UserControl to the windows form. Write some code,
compile.
This work so far.
But if I made any change in the helper project, compiling it (the
public interface of the helper.dll is untouched!) all Projects which
using the UserControl getting trouble. In all the projects the
UserControl is disappeared from "My User Controls", further, the
Windows Form Designer does not show the UserControl on the Windows Form
as where it was before. The ctlHelper.cs file is still part of the
project. The written code using the UserControl is there, too.
Compiling works too. But if I run the application the UserControl is
not shown in the Windows Form.
The problem is similar as described in KB 818220, but I am useing .NET
UserControl.
http://support.microsoft.com/?kbid=818220
Also the workaround works but it is unacceptable. This helper
repository should be used by several programmers in their projects. The
user control should gives consistency across all projects.
What to do in order to get this working?
Any help is appreciated. Thanks in advance.
cw
My goal: Creating a dll (helper.dll) which contains some UserControls
and some other helpful classes in order to use it in other projects.
Symtoms: The inital use of the UserControl component works. However, if
the Helper Project is recompiled, the UserControl does not work
correctly anymore in the other projects. Furthermore, the previously
visible User Control may not be visible in the Windows Form Designer.
Here the steps I have done:
1) Created a new Project (Helper Project)
2) Added some classes and a UserControl (there are some textboxes,
dropdown boxes, etc.)
Remark: UserControl (ctlHelper.cs)
public class ctlHelper : System.Windows.Forms.UserControl
3) Compiled the procject.
Now the next steps are including the dll in the desire project.
1) Created a new Project
2) Added a new reference to the helper.dll
3) Add -> Add Inherited Control -> Inherited User Control -> Browse to
the helper.dll location -> OK
Now the designed UserControl appears in the Toolbox of VS.2003 under
"My User Controls"
4) Drag & Drop the UserControl to the windows form. Write some code,
compile.
This work so far.
But if I made any change in the helper project, compiling it (the
public interface of the helper.dll is untouched!) all Projects which
using the UserControl getting trouble. In all the projects the
UserControl is disappeared from "My User Controls", further, the
Windows Form Designer does not show the UserControl on the Windows Form
as where it was before. The ctlHelper.cs file is still part of the
project. The written code using the UserControl is there, too.
Compiling works too. But if I run the application the UserControl is
not shown in the Windows Form.
The problem is similar as described in KB 818220, but I am useing .NET
UserControl.
http://support.microsoft.com/?kbid=818220
Also the workaround works but it is unacceptable. This helper
repository should be used by several programmers in their projects. The
user control should gives consistency across all projects.
What to do in order to get this working?
Any help is appreciated. Thanks in advance.
cw