Print Page | Close Window

WM_INITMENUPOPUP for CXTPMenuBar

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Toolkit Pro
Forum Description: Topics Related to Codejock Toolkit Pro
URL: http://forum.codejock.com/forum_posts.asp?TID=1750
Printed Date: 07 November 2025 at 8:26am
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: WM_INITMENUPOPUP for CXTPMenuBar
Posted By: skura
Subject: WM_INITMENUPOPUP for CXTPMenuBar
Date Posted: 03 February 2005 at 4:41pm

I am using CXTPMenuBar in a CXTPDialog. I would like to dynamically add a sub menu when the user clicks on a Menu in the CXTPMenuBar.

One can do that in a regular MFC application by handling WM_INITMENUPOPUP. I verified that this approach works for other menus. How can I achieve the same for the menus in CXTPMenuBar?

Thanks in advance for your help.




Replies:
Posted By: skura
Date Posted: 03 February 2005 at 6:59pm

I ended up over loading the OnControlSelected() by defining the following message map entry.

 ON_MESSAGE(WM_XTP_CONTROLSELECTED, OnControlSelected)



Posted By: Oleg
Date Posted: 04 February 2005 at 5:12am
better ON_XTP_INITCOMMANDSPOPUP, WM_XTP_INITCOMMANDSPOPUP.

-------------
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