× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Others have giving great examples on what to do.

However, I believe that what you are doing is the exact reason the
new snd-msg and on-excp have been added.  However, you need the May 2022
PTFs on 7.3 or better to have this feature.



RPGPGM1:

monitor;
    RPGPGM2();
on-excp 'CPF9898';
    // Do something about this particular error
endmon;

RPGPGM2:

// Something bad happens.
sng-msg *escape %msg('CPF9898' : 'QCPFMSG' : 'Message in joblog') %target(*caller : 1);


On 4/17/23 7:51 AM, Jay Vaughn wrote:
Let's say I have an RPGPGM1 that does the following...

monitor;
RPGPGM2();
on-error;
// check %status();
end-mon.

It is my understanding that if RPGPGM2 pgm fails, then our %status will
only report a 202 and will not give us the details as to why.
Is there anyway in RPGPGM1, to get the exact reason why RPGPGM2 failed,
without adding a msg parm on RPGPGM2 and bubbling the message up?

thanks

Jay

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

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.