Problems with CXTToolBar::LoadBitmap() |
Post Reply |
Author | |
Jonas
Newbie Joined: 15 May 2003 Location: Sweden Status: Offline Points: 2 |
Post Options
Thanks(0)
Posted: 29 October 2003 at 3:40am |
My intention is to create dynamic toolbars at run-time. However, the CXTToolBar::LoadBitmap() doesn't seem to work (i.e the button images does not show up). I tried the same code with MFC's CToolBar and that works perfectly. Here is a snippet from my code: static UINT BASED_CODE TB_IDS[] = DWORD dwStyle = WS_CHILD | WS_VISIBLE | CBRS_TOP | CBRS_GRIPPER | CBRS_TOOLTIPS | CBRS_FLYBY | CBRS_SIZE_DYNAMIC; m_wndDynToolBar.CreateEx(this, TBSTYLE_FLAT, dwStyle, CRect(0, 0, 0, 0), 59500)m_wndDynToolBar.LoadBitmap(IDB_TB); ---------- IDB_TB is a 64x15 16 color bitmap. m_wndDynToolBar is a CXTToolBar instance. Update: The bitmap images show up if xtAfxData.bXPMode is set to FALSE. Not otherwise. Regards, Jonas E Edited by Jonas |
|
Post Reply | |
Tweet
|
Forum Jump | Forum Permissions You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |