ibmi-brunch-learn

Announcement

Collapse
No announcement yet.

CL message handling

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • CL message handling

    Hi,
    I have a menu option that calls a CL that calls several other CL's which all have the possibility of failing during processing. Each program has message handling built in but how do I get a message generated in program C, that was called from program B, that was called from program A, to display to the user running the menu option to inform he/her that a program failed somewhere downstream?

    Mike
    Everyday's a school day, what grade are you in?

  • #2
    You can make each program resend the error it receives to the caller. IBM i has two good API's for this: QMHMOVPM and QMHRSNEM. I use Brian Rusch's command interfaces to these API's in my CL programs.

    You can find more information here:
    Note: The code accompanying this article is available for download here. I had the great pleasure of meeting Brian Rusch in Milwaukee last month, when I spoke to the Wisconsin Midrange Computer Professionals Association (WMCPA). Brian told me about the method his shop uses to handle CL program exceptions. I’d like to share it with

    Comment

    Working...
    X