|
I have a problem with which I hope someone can help. When I run a program with a call to another program I am getting a halt: Error occurred while calling program or procedure *LIBL/ADX002 Previous messages in the joblog:Cannot resolve to object ADX002. Type and Subtype X'0201' Authority X'0000'. Function check. MCH3401 unmonitored by OVR002 at statement 0000000080, instruction X'0000'.
Why can't the ADX002 program be found? The relevant (I think) code is: D ADX002 PR EXTPGM('ADX002')D Company 30A D Report 30A
/free ADX002(@company:@report); Not that it should matter but both programs are RPG IV.When I use the WRKOBJ command, it shows that the program (ADX002) is in my library list (below).
Work with ObjectsType choices, press Enter. Object . . . . . . . . . . . . . OBJ > ADX002 Library . . . . . . . . . . . *LIBL Object type . . . . . . . . . . OBJTYPE > *PGM
Work withObjects
Type options, pressEnter. 2=Edit authority 3=Copy 4=Delete 5=Display authority 7=Rename 8=Display description 13=Change description Opt Object Type Library Attribute Text ADX002 *PGM ADSOE200 RPGLE Retrieve
Company/Report NamIf I change the prototype to use "EXTPGM('ADSOE200/ADX002')", it works fine. The only out of the ordinary thing is that the main program is run from a menu that resides in a library that is not normally in my library list. I get to the menu using: GO PRICELIB/PCOVER. The menu option invokes the main program using: CALL PGM(PRICELIB/OVR002C). The CL (OVR002C) looks like:
PGM DCL VAR(&PREFIX) TYPE(*CHAR) LEN(1) DCL VAR(&FILE) TYPE(*CHAR) LEN(10) RTVDTAARA DTAARA(*LDA (1 1)) RTNVAR(&PREFIX) CHGVAR VAR(&FILE) VALUE(&PREFIX *TCAT '.ADTAB1') OVRDBF FILE(ADTAB1) TOFILE(&FILE) OVRDBF FILE(STRULE) TOFILE(PRICELIB/STRULE) OVRPRTF FILE(OVR002P) TOFILE(OVR002P) DEV(PF) +
PAGESIZE(66 80) LPI(6) CPI(10) PAGRTT(0) +SPOOL(*YES) FORMTYPE(*STD) SPLFNAME(STRULES) CALL PGM(PRICELIB/OVR002) ENDPGM I hope that I have included all of the necessary bits and pieces. I can, of course, leave the library hard-coded, but I don't like doing that. The called program (ADX002), by the way, is a general utility that has been in production for over a year. The call to it works fine when used in our normal menu set whether called from an RPG IV or RPG II (don't get me started) program.
Thanks.
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.