Print Page | Close Window

CheckMenuItem does not work for 3100

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=558
Printed Date: 23 December 2024 at 12:40pm
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: CheckMenuItem does not work for 3100
Posted By: qbert2004
Subject: CheckMenuItem does not work for 3100
Date Posted: 23 March 2004 at 4:00pm
Hi , Im trying to check a menu item while having Cool Menu's installed, its completely not working. This same code works for a non XT project, what gives ??


     
     CXTMenu* mmenu = (CXTMenu*)GetMenu();
     CXTMenu* submenu = (CXTMenu*)mmenu->GetSubMenu(0);


     UINT state = submenu->GetMenuState(ID_FILE_NEW, MF_BYCOMMAND);
     ASSERT(state != 0xFFFFFFFF);

     if (state & MF_CHECKED)
           submenu->CheckMenuItem(ID_FILE_NEW, MF_UNCHECKED | MF_BYCOMMAND);
     else
           submenu->CheckMenuItem(ID_FILE_NEW, MF_CHECKED | MF_BYCOMMAND);     



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