Skip to main content

TcxCustomGridTableController.FocusRecord(Integer,Boolean) Method

Moves focus to and selects a particular record.

Declaration

function FocusRecord(AFocusedRecordIndex: Integer; ASyncSelection: Boolean): Boolean;

Parameters

Name Type
AFocusedRecordIndex Integer
ASyncSelection Boolean

Returns

Type
Boolean

Remarks

The FocusRecord function moves focus to the record identified by the AFocusedRecordIndex parameter.

Use the ASyncSelection parameter to specify whether the selection should be preserved when moving focus. When this parameter’s value is equal to True the previous selection is cleared and it’s synchronized with the focused record. Set the ASyncSelection parameter to False to preserve the selection when navigating.

The FocusRecord function returns True if the specified record was successfully focused. Otherwise, False is returned.

See Also