Steve Moland wrote:
Thank you all for responding. I'm going to back up and learn a little more about the java code because I think the issue is a parameter issue from the java side. Here's why.

The RPG program is also called from other rpg programs and works perfectly.
The box I'm doing this on is V4R5 and there is no Sbreak in STRDBG. It's there on m V5R2 box but it would take too much to move all that I need there right now.
The dump of the failed program shows that the failed program failed before the first executable line of code executed.
Eval Fcycle = 1 never happened.
I need to get WDSC installed and learn to use it to a minimum level on the V5R2 box before I pursue any more of this.

thanks again for trying to help

For debugging, you could substitute a different program that just dumps out its parameters. Start with just 1 byte parameters, however many you think you are passing. Then try again with larger sizes if the beginning of the parameters look correct.

D numparms s 10i 0
C *entry plist
C parm p1 1
C parm p2 1
C parm p3 1
C eval numparms = %parms
C dump(a)
C return

To make it easier to debug this type of program in the future, it would be good to avoid letting the automatic RPG processing do anything that could cause your program to fail before it gets control (make all your files USROPN, avoid UDS data areas). Also, add a MONITOR around all your code; in the ON-ERROR, add some calls to QCMDEXC to do DSPJOB OUTPUT(*PRINT) and DSPJOBLOG OUTPUT(*PRINT).

Fmyfile IF E DISK USROPN
D qcmdexc pr extpgm('QCMDEXC')
D cmd 3000a const
D cmdlen 15p 5 const
D qcmdexc_len c 3000
/free
monitor;
// keep any existing monitors, (E) etc that you already have
// to handle normal expected errors
open myfile;
...
on-error;
// handle an unexpected error
qcmdexc ('DSPJOB OUTPUT(*PRINT)' : qcmdexc_len);
qcmdexc ('DSPJOBLOG OUTPUT(*PRINT)' : qcmdexc_len);
endmon;
*inlr = '1';
/end-free


As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

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

This mailing list archive is Copyright 1997-2022 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.