How to embed a toolbar (How to Docking A Toolbar)
Enabledocking (CBRS_ALIGN_ANY);
(! M_wndQuickConnect.Create (this, IDD_QUICKCONNECT, // IDD_QUICKCONNECT is a toolbar CBRS_TOP | CBRS_TOOLTIPS | CBRS_FLYBY | CBRS_HIDE_INPLACE, ID_VIEW_QUICKCONNECT)) // Initialize dialog bar m_wndQuickConnectif {TRACE0 ( "Failed to create dialog bar m_wndQuickConnect / n"); return - 1; // fail to create}
M_WndquickConnect.SetWindowText ("Quick Connect"); M_WndquickConnect.EnableDocking (CBRS_ALIGN_TOP | CBRS_ALIGN_BOTTOM); DockControlbar (& M_WndquickConnect);
ShowControlbar (& M_WndquickConnect, False, False);
Loadbarstate ("QuickConnectState"; Return 0;
}