TCollection.Exchange

Exchange 2 items in the collection

Declaration

Source position: classesh.inc line 563

public 
  procedure Exchange(const Index1: Integer; const index2: Integer);

Description

Exchange exchanges the items at indexes Index1 and Index2 in the collection.

Errors

If one of the two indexes is invalid (less than zero or larger than the number of items) an EListError exception is raised.

See also

Name Description
TCollectionItem.Index Index of the item in its managing collection TCollection.Items property.
Items Indexed array of items in the collection.