The Dialog class / ui.Dialog methods |
Sets the current row in the specified list.
setCurrentRow( name STRING, row INTEGER )
DEFINE x INTEGER DIALOG DISPLAY ARRAY custlist TO sa_custlist.* ... END DISPLAY ON ACTION goto_x CALL DIALOG.setCurrentRow("sa_custlist", x) ...
Moving to a different row with setCurrentRow() will not trigger control blocks such as BEFORE ROW / AFTER ROW, as the FGL_SET_ARR_CURR() built-in function does.
The setCurrentRow() method will not set the focus; You need to use NEXT FIELD to set the focus to a list. (This works with DISPLAY ARRAY as well as with INPUT ARRAY.)
If the passed row index is lower than 1, the first row will be selected. If the row index is greater than the total number of rows, the last row will be selected.
If the new current row is out of the current page of rows, the dialog will adapt the list offset to make the new current row visible.
If multi-row selection is enabled, all selection flags of rows are cleared, and the new current row gets automatically selected.