[Overview][Constants][Types][Classes][Procedures and functions][Variables][Index] Reference for unit 'Menus' (#lcl)

TMenuItem.IndexOf

Gets the ordinal position in Items for the specified menu item.

Declaration

Source position: menus.pp line 275

public function TMenuItem.IndexOf(

  Item: TMenuItem

):Integer;

Arguments

Item

  

Menu item to locate in the Items property.

Function result

Ordinal position for the specified menu item, or -1 when not found.

Description

Calls the IndexOf method in Items to locate the menu item specified in Item. The return value is -1 if Items has not been assigned in the class instance.

See also

TMenuItem.Items

  

Provides indexed access to the child menu items for the current class instance.


Version 4.0 Generated 2025-05-03 Home