|
That way, a throw() routine is nothing more than a wrapper for QMHSNDPM -- it just sends an escape message from a *MSGF... Users can create and add message descriptions to their own message files as they see fit.
With MONITOR able to trap specific error messages, you'd trap for USR0001 (or whatever) to catch the user's errors. Plus, you'd be able to use it with IBM APIs and CL commands that already return escape messages with message ids.
Jon Paris wrote:
Are you listening Barbara? <grin> - I do think we need support for a an RPG implementation of throw(). The problem right now is that when you throw an exception you still need some kind of return code in the background because RPG only signals a generic code to Monitor. There are hundreds of available status codes - it would be nice if a block was allocated as User Defined and the throw op-code allowed you to specify a specific status code that you were signaling. If I had that I'd use it for most everything.
As an Amazon Associate we earn from qualifying purchases.
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.