|
-----Message d'origine-----
[mailto:rpg400-l-bounces@xxxxxxxxxxxx] De la part de ssc1478
Screen 1 line x, column y
F20 goes to data entry screen, first field at line x1, column y1.
F12 returns from the procedure.
Screen 1 line x1, column y1
How do I get the cursor back to its original line and column?
It's been a long time since I did any dspf programming. I
know this worked years ago when I wrote it but no guarantees.
You need this in the control record in the dspf source:
A RTNCSRLOC(&CSRRCD &CSRFLD)
A 43 CSRLOC(CSRROW CSRCOL)
A CSRFLD 10A H
A CSRRCD 10A H
A CSRROW 3S 0H
A CSRCOL 3S 0H
In the rpg pgm you need get the cursor position:
Ddspfds ds
D csrPos 370 371b 0
and before displaying the next screen:
csrrow = %div(csrpos:256);
csrcol = %rem(csrpos:256);
csrloc = *on;
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.