I'm having problems with a simple overlay issue. I have a screen where a user can do an F4 and a window of the values from a table will appear in a SFL. All works well; except the new wilndow does not overlay the previous screen. THe old screen goes away and I just have this small window on my screen. I know I have done thie before. The key issue here is the when F4 is used, it calls a new program so this window is not in the intial DSPF. Here is the code. A CA03(03) A CA12(12) A R SFL01 SFL A SETMETHOD 10 O 05 2 A SETMETHDSC 30 O 05 13 A SETMETHFLE 1 O 05 45 A R SFC01 A OVERLAY A WINDOW(4 25 16 48) A SFLCTL(SFL01) A SFLSIZ(0020) A SFLPAG(0010) A SFLDSP A SFLDSPCTL A DSPRCD 3S 0H SFLRCDNBR(CURSOR) A 1 2'SETMETHD4' COLOR(WHT) A 1 16'The Members Group' COLOR(WHT) A 1 40DATE EDTCDE(Y) COLOR(WHT) A 2 2'SFC01' COLOR(WHT)A 2 16'Settlement Methods' COLOR(WHT) A 2 40TIME COLOR(WHT) A 4 2'Method' COLOR(WHT) A 4 13'Description' COLOR(WHT) A 4 43'File' COLOR(WHT) +++++++ FSETMETHDB IF E K DISK Prefix(F_) FSETMETHD4 CF E WORKSTN Prefix(S_) F SFILE(SFL01:RR1) * Define Variables D RR1 S 3S 0 ******************************************************* * Mainline Routine ******************************************************* /Free // Fill the subfile. Exsr srFillSf; // Write/Read the Subfile S_DSPRCD = 1; Exfmt Sfc01; // Get of job - Set Indicator to exit *InLr = *On; // * // Subroutine: srFillSf // * begsr srFillSf; // Now Fill the Subfile Setll *Loval SetMethDb; Read SetMethDb; DoW Not %EOF; S_SETMETHOD = F_SETMETHOD; S_SETMETHDSC = F_SETMETHDSC; S_SETMETHFLE = F_SETMETHFLE; RR1 = RR1 + 1; WRITE SFL01; Read SetMethDb; EndDo; EndSr; /End-Free [/pre]
Software/Hardware used:
V7R1 AS400</pre>
ASKED:
November 15, 2011 7:29 PM
UPDATED:
November 16, 2011 2:37 PM
KEEP often isn’t needed in the dummy format, though I haven’t worked out when it is. It also seems that the dummy format actually needs a field to be defined — I usually just define a blank constant field.
Tom