Skip to main content

DevExpress v24.2 Update — Your Feedback Matters

Our What's New in v24.2 webpage includes product-specific surveys. Your response to our survey questions will help us measure product satisfaction for features released in this major update and help us refine our plans for our next major release.

Take the survey Not interested

TcxGridBandedTableController.FocusNextColumnVertically(Integer,Boolean,Boolean) Method

Focuses the upper/lower focusable column in the current data row.

#Declaration

Delphi
function FocusNextColumnVertically(AFocusedColumnIndex: Integer; AGoForward: Boolean; AGoOnCycle: Boolean): Boolean;

#Parameters

Name Type
AFocusedColumnIndex Integer
AGoForward Boolean
AGoOnCycle Boolean

#Returns

Type
Boolean

#Remarks

A Banded Table View enables you to arrange columns in several lines by setting their Position.RowIndex properties. When a user focuses a column in the top line of the current record and presses the Down arrow key, the focus is moved to a relative column in a lower line of the same record. Pressing the Up arrow key in the last line focuses a relative column in an upper line.

The FocusNextColumnVertically function is used to focus the upper/lower column in these cases. It looks for a column relative to the AFocusedColumnIndex column in the following/preceding line(s) based on the AGoForward parameter. AGoForward specifies the direction of the search.

FocusNextColumnVertically calls the FindNextColumnVertically function to get the index of a required column. If the returned index is a valid, the corresponding column is focused. Refer to the FindNextColumnVertically description for more details.

FocusNextColumnVertically returns True, if a focusable column was found and focused. Otherwise, it returns False.

See Also