System.Classes.TInterfaceList.RemoveItem

From RAD Studio API Documentation
Jump to: navigation, search

Delphi

function RemoveItem(const Item: IInterface; Direction: TList.TDirection): Integer;

C++

int __fastcall RemoveItem(const System::_di_IInterface Item, System::Types::TDirection Direction);

Properties

Type Visibility Source Unit Parent
function public
System.Classes.pas
System.Classes.hpp
System.Classes TInterfaceList

Description

Removes the first reference to the Item parameter from the Items array. The returned value is the index of the removed item.

Call RemoveItem to remove a specific item from the Items array when its index is unknown. The value returned is the index of the item in the Items array before it was removed. After an item is removed, all the items that follow it are moved up in the index position and the Count is reduced by one.

If the Items array contains more than one copy of the pointer, only the first copy is deleted.

See Also