Chapter Contents

Previous

Next
SETROW

SETROW



Determines the characteristics of extended tables

Category: Extended Table


Syntax
Details
Examples
Example 1: Specifying an Extended Table
Example 2: Using an Extended Table as a Selection List
Example 3: Specifying a Dynamic Extended Table
Example 4: Using a Dynamic Extended Table as a Selection List
See Also

Syntax

CALL SETROW(num-rows<,num-sel<,sel-order<,dynamic>>>);

num-rows
is the maximum number of rows for the table. If the table is dynamic, num-rows can be 0.

Type: Numeric

num-sel
is the number of items a user can select from the list. To display the list for information purposes only (no selections allowed), specify 0. To specify unlimited selections, use a value such as 9999 that is larger than the number of available selections. If num-sel is 1, then selecting one row deselects any previously selected row.

Type: Numeric

sel-order
specifies the selection order:
'Y' Selected items are highlighted and are moved to the top of the list in the order in which they are selected.
'N' Selected items are highlighted, but they are not moved to the top of the list. (This is the default.)
'A' The selection list window automatically closes when the user makes a selection if only one selection is allowed. This option is valid only if num-sel is 1.
'B' Combines Y and A.

Type: Character

dynamic
specifies whether the table is dynamic:
'Y' specifies that the extended table is a dynamic table. Use the ENDTABLE routine in the getrow section to specify that no more rows are available.

Type: Character


Details

In PROGRAM entries, a regular extended table has a specified number of rows, and a dynamic extended table has an unspecified number of rows. You cannot use the SETROW statement in the getrow or putrow section of an SCL program. In order to use SETROW, you must have specified the EXTENDED TABLE attribute from the GATTR window.

You can also use both regular and dynamic extended tables as selection lists. The second and third arguments, num-sel and sel-order, define a selection list. Making an extended table a selection list automatically turns on the block cursor. Use FIELD to turn off the block cursor.

To define a dynamic table that is not a selection list, specify 0 for num-sel and ' ' for sel-order.

You can use SETROW only on extended tables. Because you can define extended tables only in SAS/AF software, you cannot use SETROW in FSEDIT or FSVIEW programs. FRAME entries must use the _setMaxrow method.


Examples

Example 1: Specifying an Extended Table

Specify an extended table that has 20 rows:

call setrow(20);

Example 2: Using an Extended Table as a Selection List

Specify a selection list that has 20 rows. Three selections are allowed, and the selections are moved to the top of the table.

call setrow(20,3,'y');

Example 3: Specifying a Dynamic Extended Table

Specify a dynamic table:

call setrow(0,0,'','y');

Example 4: Using a Dynamic Extended Table as a Selection List

Specify a dynamic table to be used as a selection list. Three selections are allowed, and the selections are not moved to the top of the table.

call setrow(0,3,'n','y');

See Also

CURTOP

ENDTABLE

TOPROW


Chapter Contents

Previous

Next

Top of Page

Copyright 1999 by SAS Institute Inc., Cary, NC, USA. All rights reserved.