SetRowHeader method: Grid class

Syntax

SetRowHeader(&array_of_cols)

Description

Use the SetRowHeader method to set grid column headers for screen reader mode (for the entire grid when there are no tab separators or for each tab separator when tab separators are present).

Parameters

Parameter Description

&array_of_cols

Specifies an array of string values containing the column names to be set as row headers. A column name is the Page Field Name of the field for the column.

In the case of a grid with no tab separators, this array can contain up to two column names.

In the case of a grid with tab separators, this array can contain up to two column names for each tab separator with the column name to be selected from the group of columns under control of that tab separator.

Returns

(Optional) A Boolean value: True if the method executed successfully; False otherwise.

Example 1

The following example is for a grid without tab separators:

Local Grid &MYGRID;

&MYGRID = GetGrid(%Page, "QRY_VIEWERS_WRK");
&GridRowHeaders = CreateArrayRept("", 0);
&GridRowHeaders.Push("QRYNAME");
&GridRowHeaders.Push("DESCR");
&MYGRID.SetRowHeader(&GridRowHeaders);

Example 2

The following example is for a grid with two tab separators:

Local Grid &MYGRID;

&MYGRID = GetGrid(%Page, "PSCONQRSSRCH_VW");
&GridRowHeaders = CreateArrayRept("", 0);
&GridRowHeaders.Push("CONQRSNAME");
&GridRowHeaders.Push("DESCR");
&GridRowHeaders.Push("QRYOWNERTRANS");
&MYGRID.SetRowHeader(&GridRowHeaders);