Help Center
Help CenterAfxNova

CMenu.GrayItemmethod

Grays the specified menu item.

WindowsmethodCMenu.incundocumented
Not documented upstream. This symbol was found in the AfxNova source but appears in no documentation topic. The signature below is read directly from the code; any description comes from the source comments.

Syntax

PRIVATE FUNCTION CMenu.GrayItem (BYVAL hMenu AS HMENU, BYVAL uItem AS DWORD, BYVAL fByPosition AS LONG = FALSE) AS BOOLEAN

Parameters

NameDescription
hMenu= A handle to the menu that contains the menu item.
uItem= The identifier or position of the menu item to get information about. The meaning of this parameter depends on the value of fByPosition.
fByPosition= The meaning of uItem. If this parameter is FALSE, uItem is a menu item identifier. Otherwise, it is a menu item position.

Return value

TRUE or FALSE. To get extended error information, use the GetLastError function. Note: The application must call the DrawMenuBar function whenever a menu changes, whether or not the menu is in a displayed window. Usage example: CMenu.GrayItem(hMenu, IDM_OPEN)

Description

Grays the specified menu item.

Reference

  • Include file CMenu.inc
  • Defined in AfxNova/CMenu.inc:516