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
close icon

Programmatically dock two controls

How can I programmatically dock two controls to the left region? so that controls appear one below another. And both controls must collapse to the left region. In other words, I want to set 1st control docking style = left 2nd control docking style = left + bottom I could do this in VS.NET IDE using drag-n-drop, but unable to do it programmatically Any suggestions or help?

8 Replies

VS Vijayanand S Syncfusion Team January 27, 2006 09:45 AM UTC

Hi , Thanks for using Syncfusion Products. You could set the docking window to bottom of the other window using the following statement: this.dockingManager1.DockControl(this.panel2,this.panel1,DockingStyle.Bottom,190); This above statement will dock a panel2 into bottom of the panel1. Please refer the attached sample and let me know if you need further assistance. Thanks, Vijay Test Sample


NK Navanith Keerthi January 27, 2006 02:19 PM UTC

I am aware of this, what I am looking for is, when you collapse Panel2, it must collapse to the left, not to the bottom


VS Vijayanand S Syncfusion Team January 27, 2006 03:55 PM UTC

Hi, This DockStyle should change according to the parent control docking style was a known issue in versions earlier than V3.3 and it has been fixed internally. Could you please let me know the version currently you are using? Please let me know if you are interested in upgrading to v3.3 or v4.1. I will let you know about the download details. Thanks, Vijay


NK Navanith Keerthi January 27, 2006 04:40 PM UTC

Vijay, Currently we are licensed to version 3.2.1.0 But I am trying with your evaluation version 4.1.0.25 in VS 2005, your example application worked as expected. When I set DockToFill property to true then panel2 collapsed to bottom instead of left. Is this a known issue? Do you have any version later than 4.1.0.25 that got this issue fixed? Thanks


VS Vijayanand S Syncfusion Team January 27, 2006 06:05 PM UTC

Hi, Sorry for the inconvenience caused. I was able to reproduce the issue when we set DockToFill mode to true and I will report this issue to our development team. We will try to fix this issue as early as possible. Thanks for bringing this issue into our attention. Regards, Vijay


MC Montesh Chhabria March 30, 2006 11:11 PM UTC

Hey , It''s pretty simple when we want to dock upto four controls as we have the four boundaries of the form to play with. I would like to have nearly eight controls docked in a predefined way as shown in the screen shot. Basically I have an XML in which the size and the location attributes of the controls shall be there. I would then need to dock based on this information. Can you guys help me out. thanks.

docking during runtime.zip


JK Joy K George Syncfusion Team April 1, 2006 09:17 AM UTC

Hi Montesh, I am looking into this issue .I will update you on monday Regards


JK Joy K George Syncfusion Team April 3, 2006 02:29 PM UTC

Hi Montesh, If you want to manipulate(loading docking layout) docking layout in a xml file, you could better use the State persist mechanism offered by the Docking Architecture.It allows us to save the docking layout in an xml file. Also If you want to specify the location for a docking control, I am afraid ,currently there is no method to implement this. As a workaround you could load the specified docking layout at runtime, by following the below steps. 1.Dock the controls in the designer. 2.Perform a trial execution and store the dockinglayout in an xml file. 3. Then for each subsequent execution you could load this specific layout by using the method LoadDockState. Please let me know ,if you have any queries regarding this. Regards, Joy

Loader.
Live Chat Icon For mobile
Up arrow icon