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

# TCustomControlFilterEdit.DoDefaultFilterItem

Provides a default routine used to examine an item in the filtered edit control.

## Declaration

Source position: editbtn.pas line 253

`protected function TCustomControlFilterEdit.DoDefaultFilterItem(`
`const ACaption: string;`
`const ItemData: Pointer`
`):Boolean; virtual;`

## Arguments

`ACaption` |  | Caption for the item passed to DoDefaultFilterItem.
`ItemData` |  | Pointer to the data for the item examined in the method.

## Function result

True when the item meets the filter condition.

## Description

Signals the OnFilterItemEx (preferred) or OnFilterItem (deprecated) event handlers (when assigned) to determine if the item meets the Filter condition. Values in ACaption and ItemData are passed as arguments to the event handlers.

The return value is True when the item matches the Filter value. The DoDefaultFilterItem method is called when the return value from the event handlers is False, or the event handlers are not assigned in the class instance.

## See also

TCustomControlFilterEdit.DoFilterItem |  | Filters items using the handlers for the control.
TCustomControlFilterEdit.OnFilterItem |  | An event handler to give extra conditions for filtering, in addition to the default behavior. Returns True if the passes the filter.
TCustomControlFilterEdit.OnFilterItemEx |  | Event handler signalled to filter data in the control using its caption or item data.