invoke GetMenu,hWnd
invoke ModifyMenu,eax,IDM_SCROLL,MF_BYCOMMAND or MF_GRAYED,IDM_SCROLL,NULL

I want my menu item to be grayed after it is selected.

The above code diables the menu item just fine but the menu item disappears altogether so it is not just grayed out.
If i use the menu item ID as the last parameter instead of NULL the menu item is still there and disabled but not grayed out.

Any help or examples appreciated.


:grin:
Posted on 2001-09-06 13:54:14 by titan
I use this to gray a menu item.

invoke EnableMenuItem,hMenu,IDM_EDIT_PASTE,MF_GRAYED

and this to enable

invoke EnableMenuItem,hMenu,IDM_EDIT_PASTE,MF_ENABLED


KetilO
Posted on 2001-09-06 14:13:15 by KetilO