Hi,
I wonder how to specify CDialogBar default size when it is created in MainFrame of a MFC/MDI project. Here is the code to crate dialog bar.
// add Dialog bar window
if (m_wndDlgBar.Create(this, IDD_ADDLGBAR,
CBRS_RIGHT|CBRS_SIZE_DYNAMIC|CBRS_FLYBY, IDD_ADDLGBAR))
{
TRACE0("Failed to create DlgBar\n");
return -1; // fail to create
}
m_wndDlgBar.EnableDocking(CBRS_ALIGN_ANY);
DockControlBar(&m_wndDlgBar);
I tried to call MoveWindow() or SetWindowPos(), but they don't work. The goal I want to achieve is when the dialogbar is created, it has fixed size(e.g. 200x300) no matter what DPI setting is. As you know, the size of dialogbar drew in resource will change as DPI setting change. So I want the dialogbar has fixed size.
Thanks in advance!
-bc