Click here to Skip to main content
15,882,278 members
Please Sign up or sign in to vote.
3.33/5 (3 votes)
See more:
Hi guys, i am in MFC Project in which am using MFC Ribbon Controls. My problem is i need add a CMFCRibbonButton into the CMFCRibbonStatusBar. CMFCRibbonButton contains image.

int CMainFrame::OnCreate(LPCREATESTRUCT lpCreateStruct)
m_wndStatusBar.AddElement(new CMFCRibbonStatusBarPane(ID_STATUSBAR_PANE1, strTitlePane1, TRUE), strTitlePane1);

m_wndStatusBar.AddExtendedElement(new CMFCRibbonStatusBarPane(ID_STATUSBAR_PANE2, strTitlePane2, TRUE), strTitlePane2);

m_wndStatusBar.AddElement(new CMFCRibbonButton(IDB_TEST, _T("Test"), 22, -1), _T("Text")); // here the button added into statusbar without small image

i dont know what's wrong, if you know explain me how to a button with image in CMFCRibbonStatusBar

Thanks in advance
Updated 11-Aug-22 3:12am

1 solution

go thru this link

Share this answer

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900