Print Page | Close Window

Hom to check a subMenu

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Command Bars
Forum Description: Topics Related to Codejock Command Bars
URL: http://forum.codejock.com/forum_posts.asp?TID=1093
Printed Date: 06 March 2025 at 4:17am
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: Hom to check a subMenu
Posted By: Zauz
Subject: Hom to check a subMenu
Date Posted: 20 August 2004 at 10:50am
Hi,
I'm looking to check dynamically a subMenu. And I can't find what's working.
Can someone help me please ???

Thanks a lot for your answer


-------------
zauz :)



Replies:
Posted By: Oleg
Date Posted: 24 August 2004 at 6:50am

See FAQ.

 

From FAQ:

 

Question:
How do I handle ON_COMMAND and ON_UPDATE_COMMAND_UI messages?

Answer:
(part I) using ON_UPDATE_COMMAND_UI

Xtreme Command Bars supports the classic MFC updating mechanism using the ON_UPDATE_COMMAND_UI macro.  For example, to make a menu or toolbar command item checked you would add the following code:

BEGIN_MESSAGE_MAP(CMainFrame, CFrameWnd)
    //{{AFX_MSG_MAP(CMainFrame)
    ...
    //}}AFX_MSG_MAP
     ON_UPDATE_COMMAND_UI(ID_EDIT_STATE,OnUpdateEditState)
END_M ESSAGE_MAP()
void CMainFrame::OnUpdateEditState(CCmdUI* pCmdUI)
{
    pCmdUI->SetCheck(m_bCheck);
    pCmdUI->Enable(TRUE);
}


-------------
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net