如何使一变灰的菜单项可以使用?(二级菜单)有源程序更好,还可加分。
解决方案 »
- 问个webbrowser的问题
- 成套技术,寻求上海、深圳的公司合作
- 关于OCX与系统消息的问题。请高手帮助
- 哪位懂TChart控件的高手进来帮帮搞!!!!
- activereport报表,在一台机器上打出乱码(方块),如何办?
- 如何让text控件中只输入1、2、3、4、5、6、7、8、9、0这几个数字,其他的内容都不允许输入?
- Com+远程连接???在线等待!!!
- 急:如何用VB6编写一个多线程同步控制程序
- SOS
- 如何调用imagelist_xxx系列API实现向Imagelist加入图标的同时添加Key(图标注释)?
- 请问在VB中如何新建Excel表?
- MSHFlexGrid 控件有没有换行的属性。
BOOL EnableMenuItem( HMENU hMenu, // handle to menu
UINT uIDEnableItem, // menu item to enable, disable, or gray
UINT uEnable // menu item flags
);
ParametershMenuIdentifies the menu. uIDEnableItemSpecifies the menu item to be enabled, disabled, or grayed, as determined by the uEnable parameter. This parameter specifies an item in a menu bar, menu, or submenu. uEnableSpecifies flags that control the interpretation of the uIDEnableItem parameter and indicate whether the menu item is enabled, disabled, or grayed. This parameter must be a combination of either MF_BYCOMMAND or MF_BYPOSITION and MF_ENABLED, MF_DISABLED, or MF_GRAYED. Value Meaning
MF_BYCOMMAND Indicates that uIDEnableItem gives the identifier of the menu item. If neither the MF_BYCOMMAND nor MF_BYPOSITION flag is specified, the MF_BYCOMMAND flag is the default flag.
MF_BYPOSITION Indicates that uIDEnableItem gives the zero-based relative position of the menu item.
MF_DISABLED Indicates that the menu item is disabled, but not grayed, so it cannot be selected.
MF_ENABLED Indicates that the menu item is enabled and restored from a grayed state so that it can be selected.
MF_GRAYED Indicates that the menu item is disabled and grayed so that it cannot be selected.
Return ValuesThe return value specifies the previous state of the menu item (it is either MF_DISABLED, MF_ENABLED, or MF_GRAYED). If the menu item does not exist, the return value is 0xFFFFFFFF.