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.
Unfortunately, activation email could not send to your email. Please try again.

Docking information at run time

Thread ID:

Created:

Updated:

Platform:

Replies:

72511 Mar 25,2008 03:09 AM Apr 15,2008 02:04 AM Windows Forms 4
loading
Tags: Tools
Adi
Asked On March 25, 2008 03:09 AM

Hi,
I need to keep track of what form certain form is docked to.
If I use OnDockAllow, I do not know whether the form was docked or not.
When I use OnDockStateChanged I do not know the target of the docking.
How can I know who is docked to who?

I'm using version 4.2.
Thanks,
Adi


Administrator [Syncfusion]
Replied On March 26, 2008 03:33 AM

Hi Adi,

Thank you for your interest in Syncfusion Products.

If your intention is to know which control's docking position is changed and the its docking style, please find the code snippet that illustrates this behaviour:

private void dockingManager1_DockStateChanged(object sender,

Syncfusion.Windows.Forms.Tools.DockStateChangeEventArgs arg)
{
if (dockingManager1.IsFloating(arg.Controls[0]))
{
MessageBox.Show(arg.Controls[0].Name + "is " + arg.Controls[0].Name.ToString() + " is in floating state");
}

else
{
MessageBox.Show(arg.Controls[0].Name + "is " + arg.Controls[0].Name.ToString() + "is docked to" +

dockingManager1.GetDockStyle(arg.Controls[0]).ToString());
}

}

Please find the simple sample in the following link:

http://websamples.syncfusion.com/samples/Tools.Windows/F72511/main.htm

If I have misunderstood your requirement, could you please explain me in detail of you requirement so that I could work in depth and provide you a better solution?

Please let me know if any concerns.

Regards,
Fathima


Adi
Replied On March 26, 2008 05:34 AM

Hi,
Thank you for your replay but it does not answer my question.
I'm asking who this ctrl is docked to, in case I have a ctrl that is not docked to a docking manager but to another form.
I need this information for layout persistence.
Unfortunately, I can not use Syncfusion built in mechanism due to existing implementation of persistence.
Regards,
Adi



Administrator [Syncfusion]
Replied On April 8, 2008 08:41 AM

Hi Adi,

Thank you for your interest in Syncfusion Products.

Please find the simple sample in the following link:

http://websamples.syncfusion.com/samples/Tools.Windows/F72511_1/main.htm

In the above sample, the panel is docked to the Form2 without using docking manager. When we click the button it displays the parent form in which the panel is docked.

If I have misunderstood your requirement, could you please provide me a simple sample, so that I could work out and provide you a better solution at the earliest?

Please let me know if any concerns.

Regards,
Fathima


Adi
Replied On April 15, 2008 02:04 AM

Thank you Fathima,
I have opened a direct track incident for this issue.
Adi


CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.

;