We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

Docking multiple controls by "stacking"

In the designer, it''s possible to dock multiple controls vertically; that is, on top of each other. You can do this by adding a bunch of controls to the form, then dragging them to one side. When dragged and if positioned correctly (aim for the title bar of the docked control), the outlining rectangle will occupy about one-half the vertical space of the host control and be equally wide. Is there a programmatic way to do this?

1 Reply

AD Administrator Syncfusion Team April 1, 2004 03:11 PM

Hi Feminella, It is possible tp programmatically create any docking layout that can be created using the designer. You could dock two controls as per your specifications above by using this code below : this.dockingManager1.DockControl(this.panel1, this, DockingStyle.Left, 150); this.dockingManager1.DockControl(this.listBox1, this.panel1, DockingStyle.Bottom, 150); Assume that panel1 and listBox1 are two controls that you wish to dock. A complete sample illustrating this is attached here. Please refer to the sample and let me know if you need any additional information. Regards, Guru Patwal Syncfusion, Inc.

Loader.
Live Chat Icon For mobile
Up arrow icon