Which RRN, the First on the Display?
FDISPLAY CF E WORKSTN
F RRN KSFILE SFLRCD
F KINFDS ###DSP
I###DSP DS
I *STATUS DSPSTS
I B 378 3790@SFLRN
@SFLRN will have the RRN for the first record on the subfile that is
displayed, that is the number
of the record that is first on the current subfile 'Page'.
If you want the RRN of the last record read with a READC, that's RRN.
IFDS.
An answer as short and indescriptive as the question.
Here is a part of the I/O-feedback area for RPG-IV. There should be no
problems to translate it to RPG-III.
FFILE00 UF F 4096 DISK USROPN
F INFSR(*PSSR)
F INFDS(File#00)
F COMMIT(CommitLVL)
*
DFile#00 DS
D F0Status 11 15S 0
D F0File 83 92A
D F0Library 93 102A
D F0Member 129 138A
D F0NbrOfKey 387 388B 0
D F0RcdNbr 397 400B 0
Look for "IO feedback" subject in whatever you are trying to work
with... I's all there.