|
Barbara Morris wrote: > ... > Hmm. I just tried this again, and it does work with anything printed by > System.out.println or System.err.println, but it doesn't seem to get the > exception information. > > I think that might be a limitation of RPG. When the RPG runtime makes > your method call, it checks for a JNI exception, and if one occurred, it > sends the RNX0301 message. The RPG runtime -could- (but doesn't > currently) call a JNI function called ExceptionDescribe that would > output the exception information to stderr. And since the RPG runtime > then handles the JNI exception, it's not possible for the RPG program to > later call ExceptionDescribe itself. > > It might be possible in the future to have an environment variable that > would tell the RPG runtime to call ExceptionDescribe for exceptions on > method calls. > The future is here. In V5R3, if you set environment variable QIBM_RPG_JAVA_EXCP_TRACE to 'Y', the RPG runtime will call ExceptionDescribe. The output will go to stderr. See the V5R3 version of the ILE RPG Programmer's guide for details.
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.