win32gui.InsertMenuItem

InsertMenuItem(hMenu, uItem, fByPosition, menuItem)

Inserts a menu item

Parameters

hMenu : int

Handle to the menu

uItem : int

The menu item identifier or the menu item position.

fByPosition : int

Boolean value of True if uItem is set to a menu item position. This parameter is set to False if uItem is set to a menu item identifier.

menuItem : buffer

A string or buffer in the format of a MENUITEMINFO structure.