Page 1 of 1
Positioning in a grid with pagination
Posted: Thu Jul 01, 2021 11:42 am
by svi
Hi,
I have a grid loader by paging. Each time I load a new page the grid is positioned on the first page while I want to position myself on the last. How to force my page number, which property manages this ... Thanks in advance;)
Re: Positioning in a grid with pagination
Posted: Thu Jul 01, 2021 2:03 pm
by Scott Klement
You may use the "subfile record number" property. (This is the same as the green-screen SFLRCDNBR DDS keyword.)
Re: Positioning in a grid with pagination
Posted: Fri Jul 02, 2021 3:14 am
by svi
I use this property well. when I debug I load my first page the rank is at 11 - then I click on Next, it loads my second page my rank is at 22 but the display is positioned on my first page (if I redo Next the second page s 'displays well without reppassing by my pgm) it's just the positioning of my pages that is not good for me ....
Re: Positioning in a grid with pagination
Posted: Fri Jul 02, 2021 2:39 pm
by Scott Klement
"my rank is at 22 but the display is positioned on my first page"
Sorry, I don't understand what you mean by "my rank" in the above sentence. Setting "subfile record number" will position the page to whichever record you list. So if row 12 is the first row on the 2nd page, you can set subfile record number to 12 and it will position to the second page.
If it helps, there's an example of a page-at-a-time subfile in the PUISAMPLES library that we provide with the product. The RPG code is PUISAMPLES/QRPGLESRC, GRID008R and the display is PUISAMPLES/QDDSSRC,GRID008D. Does that help?
Re: Positioning in a grid with pagination
Posted: Tue Jul 06, 2021 9:36 am
by svi
Yes thanks ;)