CRect rect(0, 0, 250, 250);
RecalcLayout();
m_wndDialogBar.Create(this, IDD_DIALOG1, CBRS_TOP | CBRS_TOOLTIPS|CBRS_FLYBY, IDD_DIALOG1);
m_wndDialogBar.MoveWindow(&rect, TRUE);

m_wndDialogBar.EnableDocking(CBRS_ALIGN_TOP); DockControlBar(&m_wndDialogBar, CBRS_ALIGN_TOP, &rect);
。。
m_wndDialogBar.MoveWindow(&rect, TRUE)点用都没有,没法改变 CDialogBar 大小  ?

解决方案 »

  1.   

    CDialogbar can not be resized when docked.
    u can have a try 
    DockControlBar/Float ControlBar
      

  2.   

    How To Make a Resizable Dialog Bar
    http://support.microsoft.com/default.aspx?scid=kb;en-us;143255
      

  3.   

    我依稀记得设置resize的边框属性就可以,但是效果不是太好。好像可以拉大但是拉小时有点问题。
      

  4.   

    www.bcgsoft.com
    www.codejock.com
    这两个网站提供的库很适合你的要求
      

  5.   

    create过之后先不要moveweindowCRect rect(0, 0, 250, 250);
    RecalcLayout();
    m_wndDialogBar.Create(this, IDD_DIALOG1, CBRS_TOP | CBRS_TOOLTIPS|CBRS_FLYBY, IDD_DIALOG1);RepositionBars(AFX_IDW_CONTROLBAR_FIRST,AFX_IDW_CONTROLBAR_LAST,0,reposQuery,rect);m_wndDialogBar.MoveWindow(&rect, TRUE);
    m_wndDialogBar.EnableDocking(CBRS_ALIGN_TOP); DockControlBar(&m_wndDialogBar, CBRS_ALIGN_TOP, &rect);