Creating the User Defined Command :-
The File has two Filed :-
OPTION CHAR 2
COMMAND CHAR 250
While Writing the Command some important Paramater Shorcut Required
&L = Library
&N = Object
&F = Source File
&O = Object
Option Command
000001 C CALL &O/&N
000002 X SIGNOFF
000003 AR CALL PGM(MEDPRIME/ARCSRC) PARM(&F &N &O)
000004 BR DSPPFM FILE(&L/&N)
000005 CC CHGCURLIB CURLIB(&L)
000006 CL CHGCURLIB CURLIB(&N)
000007 CD STRDFU OPTION(2)
000008 CM STRSDA OPTION(2) SRCFILE(&L/&F) ??SRCMBR()
000009 CP SBMJOB CMD(CALL PGM(SPOVRCMP) PARM(&F &N &L &S &O)) JOB(&N)
000010 CS STRSDA OPTION(1) SRCFILE(&L/&F) ??SRCMBR()
000011 CX CMPPFM NEWFILE(QCLSRC) OLDFILE(P#00000263/NEWCLSRC) OUTPUT(*PRINT)
000012 C1 CRTBNDRPG PGM(&L/&N) SRCFILE(&L/&F) SRCMBR(&N) DBGVIEW(*LIST) FIXNBR(*ZONED *INPUTPACKED) TGTRLS(*PRV)
000013 C2 CRTCLPGM PGM(&L/&N) SRCFILE(&L/&F) SRCMBR(&N) OPTION(*LSTDBG)
000014 DF DSPFFD FILE(&L/&N)
000015 DL DLTSPLF FILE(*SELECT)
000016 DM DSPMSG
000017 DO DLTOVR FILE(*ALL)
000018 DP dsppgmref PGM(&L/&N)
000019 EA EDTOBJAUT OBJ(&L/&N) OBJTYPE(&T)
000020 ED enddbg
000021 EL EDTLIBL
000022 FB CALL PGM(FEUPRO/STRFEUPDM) PARM(&L &F &N B N &T)
000023 FE CALL PGM(FEUPRO/STRFEUPDM) PARM(&L &F &N E N &T)
000024 GO GO &L/&N
000025 IF CALL PGM(PBIFSETC) PARM(&F &N &O)
000026 IN call utchkinc (&F &N &O)
000027 JL DSPJOBLOG
000028 LE SBMJOB CMD(CRTBNDRPG PGM(&O/&N) SRCFILE(&L/QRPGLESRC) SRCMBR(&N) DBGVIEW(*SOURCE) FIXNBR(*ZONED *INPUTPACKED)) JOB(&n)
000029 LO SBMJOB CMD(CRTBNDRPG PGM(&O/&N) SRCFILE(&L/QRPGLESRC) SRCMBR(&N) FIXNBR(*ZONED *INPUTPACKED)) job(&n)
000030 L1 CRTBNDRPG PGM(&O/&N) SRCFILE(&L/&F) SRCMBR(&N) DBGVIEW(*SOURCE) FIXNBR(*ZONED *INPUTPACKED)
000031 OV OVRDBF FILE(EMP) TOFILE(&L/&F) MBR(&N)
000032 RE RPGEXT/STRRPGEXT FROMFILE(&L/&F) FROMMBR(&N) TOFILE(MEDEXTDF/QRPGLESRC) COMPARE(Y)
000033 RQ RUNQRY *N &L/&N
000034 SD STRDBG PGM(*LIBL/&N) UPDPROD(*YES) OPMSRC(*yes)
000035 SL SBMJOB ??CMD(SAVLIB LIB(&N))
000036 SM SBMJOB ??CMD(SAVOBJ OBJ(&F) LIB(&L) OBJTYPE(*FILE) FILEMBR((&F (&N))))
000037 SO SBMJOB ??CMD(SAVOBJ OBJ(&N) LIB(&L))
000038 SP WRKSPLF
000039 SQ STRSQL
000040 S1 chgpf (&L/&N) maxmbrs(200)
000041 TS CALL PGM(TESTOPTC) PARM(&S &T)
000042 WA wrkactjob
000043 WM WRKOBJPDM QTEMP
000044 WO WRKOBJLCK OBJ(&L/&N) OBJTYPE(*FILE)
000045 WS WRKSBMJOB
000046 IO ?IMPPART OBJ(&L/&N) OBJTYPE(&T) TYPE(&S) PART(&N) TEXT(&X)
000047 IM ?IMPPART OBJ(&L/&F) OBJTYPE(*FILE) MBR(&N) PART(&N) LANG(&S) TEXT(&X)
000048 AP ADDPRJLIBL PRJ(&ZP) GRP(&ZG) SCAN(&ZH) SCHPTH(&ZS)
000049 RP RMVPRJLIBL
****** ******** End of report ********
On the WRKMBPDM
Press :- >Change Defaults (F18)
Option file . . . . . . . . MPPOPT
Library . . . . . . . . . KMGWRKLIB
Member . . . . . . . . . . . MPPOPT
The File has two Filed :-
OPTION CHAR 2
COMMAND CHAR 250
While Writing the Command some important Paramater Shorcut Required
&L = Library
&N = Object
&F = Source File
&O = Object
Option Command
000001 C CALL &O/&N
000002 X SIGNOFF
000003 AR CALL PGM(MEDPRIME/ARCSRC) PARM(&F &N &O)
000004 BR DSPPFM FILE(&L/&N)
000005 CC CHGCURLIB CURLIB(&L)
000006 CL CHGCURLIB CURLIB(&N)
000007 CD STRDFU OPTION(2)
000008 CM STRSDA OPTION(2) SRCFILE(&L/&F) ??SRCMBR()
000009 CP SBMJOB CMD(CALL PGM(SPOVRCMP) PARM(&F &N &L &S &O)) JOB(&N)
000010 CS STRSDA OPTION(1) SRCFILE(&L/&F) ??SRCMBR()
000011 CX CMPPFM NEWFILE(QCLSRC) OLDFILE(P#00000263/NEWCLSRC) OUTPUT(*PRINT)
000012 C1 CRTBNDRPG PGM(&L/&N) SRCFILE(&L/&F) SRCMBR(&N) DBGVIEW(*LIST) FIXNBR(*ZONED *INPUTPACKED) TGTRLS(*PRV)
000013 C2 CRTCLPGM PGM(&L/&N) SRCFILE(&L/&F) SRCMBR(&N) OPTION(*LSTDBG)
000014 DF DSPFFD FILE(&L/&N)
000015 DL DLTSPLF FILE(*SELECT)
000016 DM DSPMSG
000017 DO DLTOVR FILE(*ALL)
000018 DP dsppgmref PGM(&L/&N)
000019 EA EDTOBJAUT OBJ(&L/&N) OBJTYPE(&T)
000020 ED enddbg
000021 EL EDTLIBL
000022 FB CALL PGM(FEUPRO/STRFEUPDM) PARM(&L &F &N B N &T)
000023 FE CALL PGM(FEUPRO/STRFEUPDM) PARM(&L &F &N E N &T)
000024 GO GO &L/&N
000025 IF CALL PGM(PBIFSETC) PARM(&F &N &O)
000026 IN call utchkinc (&F &N &O)
000027 JL DSPJOBLOG
000028 LE SBMJOB CMD(CRTBNDRPG PGM(&O/&N) SRCFILE(&L/QRPGLESRC) SRCMBR(&N) DBGVIEW(*SOURCE) FIXNBR(*ZONED *INPUTPACKED)) JOB(&n)
000029 LO SBMJOB CMD(CRTBNDRPG PGM(&O/&N) SRCFILE(&L/QRPGLESRC) SRCMBR(&N) FIXNBR(*ZONED *INPUTPACKED)) job(&n)
000030 L1 CRTBNDRPG PGM(&O/&N) SRCFILE(&L/&F) SRCMBR(&N) DBGVIEW(*SOURCE) FIXNBR(*ZONED *INPUTPACKED)
000031 OV OVRDBF FILE(EMP) TOFILE(&L/&F) MBR(&N)
000032 RE RPGEXT/STRRPGEXT FROMFILE(&L/&F) FROMMBR(&N) TOFILE(MEDEXTDF/QRPGLESRC) COMPARE(Y)
000033 RQ RUNQRY *N &L/&N
000034 SD STRDBG PGM(*LIBL/&N) UPDPROD(*YES) OPMSRC(*yes)
000035 SL SBMJOB ??CMD(SAVLIB LIB(&N))
000036 SM SBMJOB ??CMD(SAVOBJ OBJ(&F) LIB(&L) OBJTYPE(*FILE) FILEMBR((&F (&N))))
000037 SO SBMJOB ??CMD(SAVOBJ OBJ(&N) LIB(&L))
000038 SP WRKSPLF
000039 SQ STRSQL
000040 S1 chgpf (&L/&N) maxmbrs(200)
000041 TS CALL PGM(TESTOPTC) PARM(&S &T)
000042 WA wrkactjob
000043 WM WRKOBJPDM QTEMP
000044 WO WRKOBJLCK OBJ(&L/&N) OBJTYPE(*FILE)
000045 WS WRKSBMJOB
000046 IO ?IMPPART OBJ(&L/&N) OBJTYPE(&T) TYPE(&S) PART(&N) TEXT(&X)
000047 IM ?IMPPART OBJ(&L/&F) OBJTYPE(*FILE) MBR(&N) PART(&N) LANG(&S) TEXT(&X)
000048 AP ADDPRJLIBL PRJ(&ZP) GRP(&ZG) SCAN(&ZH) SCHPTH(&ZS)
000049 RP RMVPRJLIBL
****** ******** End of report ********
On the WRKMBPDM
Press :- >Change Defaults (F18)
Option file . . . . . . . . MPPOPT
Library . . . . . . . . . KMGWRKLIB
Member . . . . . . . . . . . MPPOPT
No comments:
Post a Comment