Vcl.Menus.TMenuItem.Delete

From RAD Studio API Documentation
Jump to: navigation, search

Delphi

procedure Delete(Index: Integer);

C++

void __fastcall Delete(int Index);

Properties

Type Visibility Source Unit Parent
procedure
function
public
Vcl.Menus.pas
Vcl.Menus.hpp
Vcl.Menus TMenuItem

Description

Removes a menu item from the Items property array.

Call Delete to remove a menu item and all its submenus from a menu. The Index parameter is the index of the item to be deleted, where 0 specifies the first item in the menu, 1 specifies the second item, and so on.

Delete does not free the removed item's memory. To remove an item from the menu and free its memory, call the Free method in the item you want to remove.

To temporarily hide a menu item, without deleting it, use the Visible property.

See Also