I have an MDI app with two toolbars docked in a single row (using DockControlBarLeftOf). I want to dock both toolbars to the top, but I want the toolbar to the right to be all the way to the right not docket the one on the left. I know I am using dockcontrolbarleftof, but this is to get both bars in the same row. I tried moving the toolbar on the right all the way to the right using movewindow but did not work. I tried CReBar, but CReBar creat a line seperator above the tollbars which makes it ugly looking. Actually, using CReBar control works, but It draws that line seperator, specially when both toolbars are not the same height size. I am using C++ and MFC in VS2003
Maybe you could use a CalcFixedLayout()/CalcDynamicLayout() override to return the width of the toolbar(s). The right toolbar would be the width of the controls contained within. The width of the left toolbar would be the parent window's client area width minus the width of the right toolbar. Mark "SQL SERVER USER - DISPLAY - NAME" wrote: > I have an MDI app with two toolbars docked in a single row (using > DockControlBarLeftOf). > > I want to dock both toolbars to the top, but I want the toolbar to the right > to be all the way to the right not docket the one on the left. I know I am > using dockcontrolbarleftof, but this is to get both bars in the same row. I > tried moving the toolbar on the right all the way to the right using > movewindow but did not work. I tried CReBar, but CReBar creat a line > seperator above the tollbars which makes it ugly looking. Actually, using > CReBar control works, but It draws that line seperator, specially when both > toolbars are not the same height size. > > I am using C++ and MFC in VS2003