Making custom controls show up in Designer Toolbar

aewarnick

Well-known member
Joined
Jan 29, 2003
Messages
1,031
divil, I read your article on Designers and there is one part that confuses me. Why is the internal class inside the control class? I had to put the internal class outside becuase it was not known inside to [Designer(typeof(MyControlDesigner))].

Is that a mistake or am I doing something wrong?

C#:
[Designer(typeof(MyControlDesigner))]
public class UserControl1 : System.Windows.Forms.UserControl
{
	public UserControl1()
	{	
	}

internal class MyControlDesigner : System.Windows.Forms.Design.ControlDesigner
	{

	}
}
 
Which article are you talking about? I dont think either of my designer ones have a designer class inside the control class.
 
Im looking at the code for that article, still not seeing a class embedded within a class?
 
Sorry to trouble you divil. My mistake. After a closer look I saw that the internal class was in the namespace brackets and not the other class.
 
Back
Top