SeanHoppe.com › EXTOL EDI Examples › EXTOL Exit Point RPG Programs › EXTOL RPG Program: EXTTOC
H/TITLE API: example pgm to be called by override type "C" H 1 Y Z* CRTRPGPGM Z* OPTION(*NOXREF) GENOPT(*OPTIMIZE) * W* Warning: This program does not set on the LR indicator * H* SYNOPSIS : H* Perform user function H* As defined by action diagram * H* Generated by : Synon/2E Version: 9062 H* Function type : Execute external function * H* Company : ExtoL, Inc. H* System : ExtoL EDI Integrator H* User name : EXTOLOWN H* Date generated: 02/21/92 Time : 20:52:50 H* (C) Copyright : ExtoL, Inc. 1988,1992 * *================================================================ M* 02/23/92 JB modified copy of EXXTOE for demo *================================================================ * Data structures: IPGMDS ESDSEXPGSDS * Program data structure * Parameter declarations IP1PARM DS * FLD: Trading pnr msg class ovr * I : Trading partner code I 1 6 P1TPCD * I : Group code I 7 12 P1GPCD * I : Message ID I 13 18 P1MSID * I : Message class I 19 28 P1MSCL * I : Direction code (override) I 29 29 P1DRTO * I : Override sequence (int) I P 30 310P1OVSI * I : Override sequence I P 32 330P1OVSQ * I : Application file name I 34 43 P1GFIL * I : Override command type I 44 44 P1OVCM * I : Override to library I 45 54 P1OVLB * I : Override to file I 55 64 P1OVFL * I : Override to member I 65 74 P1OVMB IP2PARM DS * FLD: Incoming generic index * I : Connection log number I P 1 40P2CNLN * I : Interchange log number I P 5 90P2INLN * I : Group log number I P 10 140P2GPLN * I : Message log number I P 15 200P2MSLN IP3PARM DS * FLD: Translation job * I : Translation job status I 1 1 P3TJST * I : Translation job name I 2 11 P3TRJB * I : Translation job user name I 12 21 P3TRJU * I : Translation job number I 22 27 P3TRJN * I : Msg queue - translation I 28 37 P3MSQT /EJECT ***************************************************************** * Entry parameters C *ENTRY PLIST C P1TPCD PARM WP0001 6 Trading partner C P1GPCD PARM WP0002 6 Group code C P1MSID PARM WP0003 6 Message ID C P1MSCL PARM WP0004 10 Message class C P1DRTO PARM WP0005 1 Direction code C P1OVSI PARM WP0006 30 Override sequen C P1OVSQ PARM WP0007 30 Override sequen C P1GFIL PARM WP0008 10 Application fil C P1OVCM PARM WP0009 1 Override comman C P1OVLB PARM WP0010 10 Override to lib C P1OVFL PARM WP0011 10 Override to fil C P1OVMB PARM WP0012 10 Override to mem C P2CNLN PARM WP0013 70 Connection log C P2INLN PARM WP0014 90 Interchange log C P2GPLN PARM WP0015 90 Group log numbe C P2MSLN PARM WP0016 110 Message log num C P3TJST PARM WP0017 1 Translation job C P3TRJB PARM WP0018 10 Translation job C P3TRJU PARM WP0019 10 Translation job C P3TRJN PARM WP0020 6 Translation job C P3MSQT PARM WP0021 10 Msg queue - tra ***************************************************************** * Initialise C EXSR ZZINIT * * OVRDBF API pgm example * User defined routine for non-override fuction: C EXSR UASUBR User defined ro * *---------------------------------------------------------------- * Exit program C EXSR ZYEXPG *================================================================ /EJECT CSR UASUBR BEGSR *================================================================ * User defined routine for non-override function: *================================================================ * Do RPG formatted dump: C DUMP *================================================================ CSR UAEXIT ENDSR * CSR ZYEXPG BEGSR *================================================================ * Exit program: Direct *================================================================ * Copy any undisplayed messages back to caller C CALL 'Y2CPMSC' C PARM ##PGM * * Exit program C RETRN * *================================================================ CSR ZYEXIT ENDSR /EJECT CSR ZZINIT BEGSR *================================================================ * Initialisation *================================================================ * Initialise indicators for re-entry C MOVE '0' *IN *================================================================ CSR ZZEXIT ENDSR