Read-only record list (DISPLAY ARRAY) / Using read-only record lists |
This section describes the options that can be specified in the ATTRIBUTES clause of the DISPLAY ARRAY instruction. The options of the ATTRIBUTES clause override all default attributes and temporarily override any display attributes that the OPTIONS or the OPEN WINDOW statement specified for these fields. With the DISPLAY ARRAY statement, the INVISIBLE attribute is ignored.
The HELP clause overrides the HELP attribute.
When using a dynamic array, the number of rows to be displayed is defined by the number of elements in the dynamic array; the COUNT attribute is ignored.
When using a static array or the paged mode, the number of rows to be displayed is defined by the COUNT attribute. You can also use the SET_COUNT() built-in function, but it is supported for backward compatibility only. If you don't know the total number of rows for the paged mode, you can specify -1 for the COUNT attribute (or in the SET_COUNT() call before the dialog block): With COUNT=-1, the dialog will ask for rows by executing ON FILL BUFFER until you provide less rows as asked, or if you reset the number of rows to a value higher as -1 with ui.Dialog.setArrayLength().
Depending on the list container used in the form, the current row may be highlighted during the execution of the dialog, and cleared when the instruction ends. You can change this default behavior by using the KEEP CURRENT ROW attribute, to force the runtime system to keep the current row highlighted.
The ACCEPT attribute can be set to FALSE to avoid the automatic creation of the default accept action. Use this attribute when you want to avoid dialog validation, or if you need to write a specific validation procedure by using ACCEPT DISPLAY.
The CANCEL attribute can be set to FALSE to avoid the automatic creation of the cancel default action. Use this attribute when you only need a validation action (accept), or when you want to write a specific cancellation procedure by using EXIT DISPLAY.
If the CANCEL=FALSE option is set, no close action will be created, and you must write an ON ACTION close control block to create an explicit action.
The DOUBLICKCLICK option can be used to define the action that will be fired when the user chooses a row from the list. On front-end platforms using a mouse-device, this corresponds to a physical double-click on a row with the mouse. On mobile front-ends, this corresponds to a tap on the row with a finger. Note that this attribute can also be defined for the TABLE/TREE containers in form files; DOUBLECLICK in DISPLAY ARRAY attributes has a higher precedence as DOUBLECLICK in the form file. For more details, see Defining the action for a row choice.
The DETAILACTION attribute can be used to define the action that will be fired when the user selects the detail button of a row. The detail button is typically shown with a (i) icon on iOS devices. Note that the DOUBLECLICK attribute can be used to distinguish the action when the user selects the row instead of the detail button in the row. For more details, see Row configuration on iOS devices.
The ACCESSORYTYPE attribute can be used to define the decoration of rows, typically used on a iOS device. Values can be DETAILBUTTON, DISCLOSUREINDICATOR, CHECKMARK to respectively get a (i), > or checkmark icon. For more details, see Row configuration on iOS devices.