开发者

How to prevent panel from changing its children controls' sizes

开发者 https://www.devze.com 2022-12-09 13:40 出处:网络
I have a panel which is hosting a Treeview and a User Control. The panel itself is residing within a window form. When I maximize the window form, the panel size get changed automatically and the Tree

I have a panel which is hosting a Treeview and a User Control. The panel itself is residing within a window form. When I maximize the window form, the panel size get changed automatically and the Treeview within it.

Is there a way to prevent the panel from changing the children control within it automatically?

I开发者_C百科 am using visual studio 2008 and C# language.

Thanks


Set the TreeView .Anchor property to None. If the .Dock property has a value set it to None also. These two properties represent auto-resize features of a control relevant its parent container (which in your case is the Panel)

0

精彩评论

暂无评论...
验证码 换一张
取 消