Using MF_GRAYED

This is a discussion on Using MF_GRAYED within the Windows Programming forums, part of the Platform Specific Boards category; Im using MF_GRAYED for my menu, but I dont know how to make it ungrayed. can someone help, thank you. ...

  1. #1
    Registered User
    Join Date
    May 2004
    Posts
    215

    Using MF_GRAYED

    Im using MF_GRAYED for my menu, but I dont know how to make it ungrayed. can someone help, thank you. :-)

  2. #2
    Registered User
    Join Date
    May 2004
    Posts
    215
    nevermind i got it, i guess my problem is, my commands dont work

  3. #3
    Registered User
    Join Date
    May 2004
    Posts
    215
    Heres my code, my commands wont work:

    Code:
    case ID_FILE_CONNECT:
    
    
    
               EnableMenuItem(hMenu,ID_FILE_CONNECT,MF_DISABLED);
    	       EnableMenuItem(hMenu,ID_FILE_CONNECT,MF_GRAYED);
               EnableMenuItem(hMenu,ID_FILE_DISCONNECT,MF_ENABLED);
    	
    
    
    		break;
    
    		case ID_FILE_DISCONNECT:
    
    			  EnableMenuItem(hMenu,ID_FILE_DISCONNECT,MF_DISABLED);
    	          EnableMenuItem(hMenu,ID_FILE_DISCONNECT,MF_GRAYED);
                  EnableMenuItem(hMenu,ID_FILE_CONNECT,MF_ENABLED);
    
    
    		break;
    however, nothing works. connect is set to disabled since we connect first, so disconnect is enabled. but when i click disconnect, nothing happens, everything stays the same when in reality disconnect should then become disabled and connect enabled.

  4. #4
    Registered User
    Join Date
    May 2004
    Posts
    215
    nevermind i got it :-)

Popular pages Recent additions subscribe to a feed

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21