Previous Topic: NEXT CommandNext Topic: PREVIOUS Command


POSITION Command

The POSITION command positions a specific line at the top of the region.

This command has the following format:

POSITION n
n

For programs, members, and report definitions, n is the sequence number of the line to position at the top of the region.

For outputs and panel layouts, n is the absolute line number in that component. (1 is the first line, 2 is the second line, and so on).

For the panel field summary table, n is the field number; for example, POSITION 7 brings the row for field 7 to the top of the region in the layout portion and the entry for field 7 to the top of the table portion of the region.

Example

The following example positions line 1612 at the top of the region.

=> POSITION 1612 ....+....1....+....2....+....3....+....4....+....5....+....6....+....7....+.... IDEAL: PROCEDURE DEFINITION PGM CRTEST (001) TEST SYS: $ID FILL-IN Command....+....1....+....2....+....3....+....4....+....5....+....6....+....7.. ====== ================================ T O P ================================= 001602 SET NEXT_PANEL = 'EMPMENU' 001603 WHEN $PF12 001604 DO TERMINATE_SES 001605 WHEN OTHER 001606 FOR EACH EMPLOYEE 001607 WHERE STATE_ADDRESS = 'CA' OR 'IL' 001608 AND NUMBER > 125 AND < 150 001609 FOR PAYROLL 001610 WHERE NUMBER = EMPLOYEE.NUMBER 001611 AND NUMBER > 100 AND < 150 001612 SET SALARY = YTD_WAGES + YTD_COMMISSION - YTD_TAX 001613 SET STATE1 = 'CA' 001614 SET STATE3 = 'MO' 001615 SET STATE2 = 'IL' 001616 PRODUCE CARM1 001617 ENDFOR 001618 ENDFOR

Line 1612 is now at the top of the region with subsequent lines filling the region.

=>

....+....1....+....2....+....3....+....4....+....5....+....6....+....7....+.... IDEAL: PROCEDURE DEFINITION PGM CRTEST (001) TEST SYS: $ID FILL-IN Command....+....1....+....2....+....3....+....4....+....5....+....6....+....7.. 001612 SET SALARY = YTD_WAGES + YTD_COMMISSION - YTD_TAX 001613 SET STATE1 = 'CA' 001614 SET STATE3 = 'MO' 001615 SET STATE2 = 'IL' 001616 PRODUCE CARM1 001617 ENDFOR 001618 ENDFOR 001619 FOR EACH EMPLOYEE 001620 FOR EACH EMPLOYEE 001621 ORDERED BY STATE_ADDRESS CITY_ADDRESS EMPLOYEE.NAME 001622 WHERE STATE_ADDRESS = 'CA' OR 'IL' 001623 AND NUMBER > 125 AND < 150 001624 WHEN $PF11 001625 SET DISPANEL.MSG = 'UNABLE TO INTERPRET KEY ENTERED' 001626 SET NEXT_PANEL = 'DISPANEL' 001627 ENDSEL