Avoid “black screen” between two processes in CL program

25 pts.
Tags:
CL Program
PGM
RPG
Hi guys,
I have my CL proc, inside it I call my PGM1 and PGM2,
.....
CALL       PGM(MYLIB/PGM1)
CALL       PGM(MYLIB/PGM2)
...
PGM1 excpt a screen and I fill it then press F8. with F8 seton LR, end PGM1 and start PGM2 that process file data with parameters passed from PGM1 and give me print output but in the time that elapses between end PGM1 and end PGM2 the screen is black. Is there any way to leave on first screen?
Thank you!
(the two PGM are RPG IV fixed format)


Software/Hardware used:
iSeries 7.1
1

Answer Wiki

Thanks. We'll let you know when a new response is added.

Call PGM2 from PGM1 at LR TIME.

Discuss This Question: 3  Replies

 
There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.
  • ToddN2000
    Another option is replave the "CALL       PGM(MYLIB/PGM2)" to a SBMJOB and pass the parameters. Let it run in batch and return to the initial prompt screen. This way if you need to run multiple versions of PGM2 you could stack them in a JOBQ for processing without locking the screen.
    132,840 pointsBadges:
    report
  • GregManzo
    Todd's approach is best practice solution and provides the user with a quick 'response time' while PGM2 is running. We have a 'pattern' COPY member that provides a generic PGM1 selection screen to accept parameters and then issue a SBMJOB. This works well for any given PGM2 that doesn't need a screen.
    2,960 pointsBadges:
    report
  • GregManzo
    If however, PGM2 needs to show results on screen, then batch doesn't work well (without a lot of over-engineering). In that case the easiest option is to call PGM2 from PGM1 before it has closed the display file ('cos this is what actually blanks the screen). There are other possibilities (KEEP & ASSUME keywords etc.) but they are more effort than is necessary.
    2,960 pointsBadges:
    report

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

To follow this tag...

There was an error processing your information. Please try again later.

Thanks! We'll email you when relevant content is added and updated.

Following

Share this item with your network: