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.

Best control for a status bar?

Thread ID:

Created:

Updated:

Platform:

Replies:

328 Jun 3,2002 04:33 PM Jun 5,2002 08:36 PM Windows Forms 3
loading
Tags: Tools
David Palau
Asked On June 3, 2002 04:33 PM

What would be a better control for a status bar type of control: a XPToolBar, a Toolbar with a BarManager, or a CommandBar? Basically I would like to get a 'Office XP' style, flat status bar with 3 sections. Any suggestions?

Administrator [Syncfusion]
Replied On June 4, 2002 01:00 PM

There are a number of things you can do here. If all you need is 3-sections with flat look, then I recommend that you use the StatusBar control and owner draw the panels to get the flat-look. Owner drawing a 1 line border should be very easy. There should some code in our WinForms FAQ that should help you with this. Search for "StatusBar". If you do decide to take this approach and if you app also has XPMenus or uses command bars, then put the StatusBar inside a CommandBar, so that the other commandbars and toolbars in your app will show above the status bar. If you are using XPMenus in your app, add a "detached command bar" to the manager into which you can place a StatusBar. Take a look at the MainFrameBarManager.DetachedCommandBars property reference. Make sure to set the AlwaysLeadingEdge property to true for the command bar. If on the other hand, if you need to place some controls into the toolbar, use a commandbar (with the above settings) containing a Panel with DockStyle.Fill. Then within this Panel place a StatusBar to the right (for the gripper) and whatever Control(s) you need to the left. You might have to do some layout management during resisizng here. Use our FlowLayout, if necessary. The resultant UI should look pretty neat. -Praveen Ramesh

David Palau
Replied On June 5, 2002 02:18 PM

Thanks. I found an example in C#. For what it is worth, I converted and tweaked it for our project in VB.NET. I included the source if anyone is interested. I followed the route of actually having a CommandBar docked at the bottom that contains my flat status bar, but I can't seem to make the CommandBar *always* stay at the bottom. I can drag other toolbars and make them dock below the CommandBar (which pushes the status bar up). Any idea how I can always make the CommandBar be at the bottom?

Prakash S [Syncfusion]
Replied On June 5, 2002 08:36 PM

David, Setting the statusbar CommandBar's CommandBar.AlwaysTrailingEdge property to TRUE will make it non-floatable and force it to always remain at the bottom of the particular dock border(the bottom border in this case). To get the complete StatusBar effect, you might also want to set the CommandBar.HideGripper, CommandBar.HideDropDownButton, CommandBar.HideChevron and CommandBar.OccupyFullRow properties to TRUE. Thanks, Prakash

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.

;