2,030 pts.
 Retain the values in the inital screen after coming back from the popup window
I have a screen which displays the account numbers. If i input some values to this account field and when i do an F5(without hitting enter) I can see the popup window, but after coming back from the pop up screen, my account numbers are gone. I have used CA05 for the popup. If I use CF05 and then take F5, the account numbers will get updated in my file(the code to do this is under When *in05 = *ON) which I don't want to happen unless user hits enter. Without using CF05, is there any way to retain the account numbers on the initial screen till user press enter?

Software/Hardware used:
AS400
ASKED: January 24, 2013  2:15 PM
UPDATED: January 24, 2013  2:27 PM

Answer Wiki:
When you CRTDSPF, use RSTDSP(*YES)
Last Wiki Answer Submitted:  January 24, 2013  3:01 pm  by  CharlieBrowne   33,730 pts.
All Answer Wiki Contributors:  CharlieBrowne   33,730 pts. , Michael Tidmarsh   14,060 pts.
To see all answers submitted to the Answer Wiki: View Answer History.


Discuss This Question:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _


 

I have tried with RSTDSP(*YES), still it is not retaining the values after coming from the popup window. Please advice

 2,030 pts.

 

I thought this is quiet simple.. I tried assume keep and all.. but no luck so far

 2,030 pts.

 

Then we need to see the display DDS and the programming that receives the F5-key and returns to the screen. We can’t tell you what’s happening without seeing the code. — Tom

 110,135 pts.

 

I’m very confused, again. 
If the display issues CA05 .. it returns the original data to the program.
I would use CF05 but then I would have the program doing very different things when F5 is pressed. 
 
Did you use the same names for physical file fields and display fields?
 

 44,630 pts.

 

You’ll need to store the data entered until needed.  Pressing F5 on the display will return control to the program (if using CA05 the data entered will not be returned); if the program does not have the data stored, it won’t be able to re-display it when the pop-up window is closed.

 5,740 pts.

 

…(the code to do this is under When *in05 = *ON)
 
That’s the first part that I don’t understand and that needs to be explained. It shouldn’t matter if it’s CA05 or CF05. The *IN05 indicator shouldn’t have any connection to an update if it’s intended for a pop-up window, and it probably shouldn’t matter if CA or CF is used. If it does matter, then the program logic should be changed so that it doesn’t.
 
What is the purpose of the pop-up window? If it supplies a value to fill in a field on the screen, then the program is outputting the screen again. RSTDSP() wouldn’t matter in most programs if that’s the case, but maybe the PUTOVR (Put with Explicit Override) keyword would help.
 
Tom

 110,135 pts.