tags:

views:

32

answers:

1

I have a panel being used like a subform. What I would like is to restrict the panel to some maximum size. When the form is maximized or resized, the subform is resized only to some maximum height and width. Couldn't find a property to limit the size of the panel so I did it manually by handling its resize event. That's okay because it's only one control.

The problem is with the controls inside the panel. I thought it was simply a matter of anchoring some of the controls to the panel. Wrong! It looks like they're being anchored to the form. Any solultions besides manually resizing all the controls?

+1  A: 

Make sure that the controls have been added to the Controls collection of the Panel. If they have, your scenario should work as expected.

Chris Taylor
Thanks Marc and Chris. I double checked and found my codes suck big time. This was my first question on stackoverflow and it shows.
bricklayer137