Question Adding properities to child components


New member
Apr 2, 2013
Programming Experience
The tablelayoutgrid adds properties to controls dropped on it. I want to learn how to do this. Can anyone point me in the right direction?
It's a TableLayoutPanel. Please use the correct names for things to avoid confusion. It was obvious in this case what you actually meant but may not always be.

What you're asking for is done by implementing the IExtenderProvider interface. Another example of this is the ToolTip component. The properties you speak of are not actually properties. They appear in the Properties window in the designer because the VS designer understands the IExtenderProvider interface but, if you want to access that functionality in code, it's actually done via methods of the provider rather than properties of the client component.

Here's an example I created that uses the IExtenderProvider interface to approximate the control array functionality available in VB6. The code is VB.NET but the principles are exactly the same.

Control Arrays in VB.NET

Latest posts

Top Bottom