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

# TCustomListView.OnInsert

Event handler signalled when a list item is added to or inserted in the Items for the control.

## Declaration

Source position: comctrls.pp line 1613

`protected property TCustomListView.OnInsert : TLVInsertEvent read FOnInsert write FOnInsert;`

## Description

OnInsert is a TLVInsertEvent property with the event handler signalled when a new TListItem instance is stored in the Items property. Arguments to the event handler include the object (TCustomListView) for the notification and the TListItem instance for the action.

OnInsert is signalled (when assigned) from the DoInsert method, and occurs when the ItemInserted method is called. This happens after the list item has been added to a TListItems container.

## See also

TCustomListView.DoInsert |  | Performs actions needed to insert the specified list item.
TCustomListView.ItemInserted |  | Performs actions when a list item has been inserted in the Items collection.
TListItems.AddItem |  | Adds the specified list item to the storage for the container.