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. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Move Floating Menu Bar

Thread ID:

Created:

Updated:

Platform:

Replies:

92088 Dec 17,2009 09:53 PM UTC Dec 18,2009 12:41 PM UTC WinForms 1
loading
Tags: Tools
Truman Lackey
Asked On December 17, 2009 09:53 PM UTC

I have a form with menubars on it. I want to be able to set the position of a menubar that is floating.

I have tried the following:

CommandBar cb = bar.Manager.GetBarControl(bar);

cb.FloatBounds = ????;
cb.RowIndex = ???;
cb.RowOffset = ???;
cb.Location = ???;

Setting the above does not move a floating menu bar.

What is the correct way to change the position of a floating bar?

Githanjali S [Syncfusion]
Replied On December 18, 2009 12:41 PM UTC

Hi Truman,

Please follow the below steps:

// Get the CommandBarExt object associated with the Bar
CommandBarExt cmdBarExt = this.mainFrameBarManager1.GetBarControl(this.bar2) as CommandBarExt;

// Get the CommandbarExt's parent CommandDockBar
CommandDockBar cmdDockBar = cmdBarExt.Parent as CommandDockBar;

// Set the CommandDockBar's desired position
cmdDockBar.Location = new Point(0,0);

cmdBarExt.DockState = CommandBarDockState.Float;

Let me know if this works for you.

Regards,
Githanjali

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.

Warning Icon 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.Close Icon

;