Ü
ROLLDOWN / ROLLUP
·
The ROLLUP keyword
is the same as the PAGEDOWN keyword. The ROLLDOWN keyword is the same as the
PAGEUP keyword. Roll is the same as page.
·
This keyword is
used at file or record level to control the ROLL DOWN and ROLL UP activity for
the subfile.
·
We assign a
response indicator with this keyword and handle the activity with these
indicators.
·
The format of the
keyword is as shown below:
ROLLDOWN(
Response Indicator)
ROLLUP(Response
Indicator)
Example
Columns . . . : 1 80 Browse AMIT/QRPGLESRC
SEU==> SNGL_DSP
FMT DP .....AAN01N02N03T.Name++++++RLen++TDpBLinPosFunctions+++++++++++++++++++++++++++
*************** Beginning of data **********************************************
0001.00 A DSPSIZ(24 80 *DS3)
0002.00 A CA03(03 'EXIT')
0003.00 A ROLLUP(66) >>>>>>>>>>>>>
0005.00 A ROLLDOWN(44) >>>>>>>>>>>>>
0007.00 A R HEADER
0008.00 A OVERLAY
0009.00 A 1 3USER
0010.00 A DSPATR(HI)
0011.00 A COLOR(BLU)
0012.00 A 1 71DATE
0013.00 A EDTCDE(Y)
0014.00 A DSPATR(HI)
0015.00 A COLOR(BLU)
0016.00 A 2 71TIME
0017.00 A DSPATR(HI)
0018.00 A COLOR(BLU)
0019.00 A 1 23'DISPLAY THE SINGLE PAGE SUBFILE'
0020.00 A DSPATR(HI)
0021.00 A COLOR(BLU)
0022.00 A R FOOTER
0023.00 A OVERLAY
0024.00 A 23 7'F3'
0025.00 A DSPATR(RI)
0026.00 A COLOR(WHT)
0027.00 A 23 10'= EXIT'
0028.00 A 23 26'F12'
0029.00 A DSPATR(HI)
0030.00 A DSPATR(RI)
0031.00 A 23 30'=PREVIOUS'
0032.00 A R EXPD_SFL SFL
0033.00 A 56 SFLNXTCHG
0034.00 A S_ORG 3S 0O 8 12
0035.00 A S_ACC 12A O 8 28
0036.00 A S_CCY 3A O 8 49
0037.00 A R EXPD_CTL SFLCTL(EXPD_SFL)
0038.00 A OVERLAY
0039.00 A 52 SFLDSP
0040.00 A 51 SFLDSPCTL
0041.00 A 50 SFLCLR
0042.00 A 45 SFLEND(*MORE)
0043.00 A SFLSIZ(0005)
0044.00 A SFLPAG(0005)
0045.00 A 6 12'ORG CODE'
0046.00 A 6 27'ACCOUNT NUMBER'
0047.00 A 6 48'CURRENCY'
****************** End of data *********************************************
Now we can handle the ROLL
UP and ROLL DOWN with the response indicator 66 and 44.
0022.00 C*
0023.00 C*__________________ROLL UP____________________
0024.00 C*_____________________________________________
0025.00 C *IN66 IFEQ *ON
0026.00 C IF *IN45=*OFF
0027.00 C EXSR CLRSFL
0028.00 C EXSR NXTPAG
0029.00 C EXSR FILSFL
0030.00 C EXSR DSPSFL
0031.00 C ELSE
0032.00 C EXSR DSPSFL
0033.00 C ENDIF
0034.00 C ENDIF
0035.00 C*
0036.00 C*__________________ROLL DOWN__________________
0037.00 C*_____________________________________________
0038.00 C *IN44 IFEQ *ON
0039.00 C EXSR CLRSFL
0040.00 C EXSR PREPAG
0041.00 C EXSR FILSFL
0042.00 C EXSR DSPSFL
0043.00 C ENDIF
0044.00 C*____________________________________________
0045.00 C IF *IN66=*OFF AND *IN44=*OFF
0046.00 C EXSR DSPSFL
0047.00 C ENDIF
0048.00 *
0049.00 C ENDSR