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

Getting the size of an AutoHide''n control under DockingManager

Is there a way of getting the size of a docked control that has AutoHide == true?

If I look at the control.Size or control.Parent.Size etc, they are 0,0 but obviously the DockingManager knows the size to show when the tab is clicked.

There is a dockingManager.SetControlSize() method but I almost need a GetControlSize() method.

Thanks.

1 Reply

MU Murugan Syncfusion Team March 12, 2007 06:20 PM UTC

Hi Jas_sl,

We could get the control size of the Docked control when AutoHide = true, using DockInfo class. DockInfo details could be retrived from DockHostController class. Here is the sample code snippet

private void button1_Click(object sender, EventArgs e)
{

DockHost dh = this.listView1.Parent as DockHost;
DockHostController dhc = dh.InternalController as DockHostController;
DockInfo di = dhc.DITransient;
Console.WriteLine(di.rcDockArea.ToString());

}

In the sample code, ListView1 docked ControlSize is written on Console when button is clicked. Please try this and let me know if it helps you.

Thank you for using Syncfusion products.

Regards,
Murugan P.S


Loader.
Live Chat Icon For mobile
Up arrow icon