ibmi-brunch-learn

Announcement

Collapse
No announcement yet.

OVRPRTF not working

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • OVRPRTF not working

    Good afternoon, trying this new printer file I created, and I was trying to enlarge the font, but I realized that the OVRPRTF command was not working.

    I have tried the ovrscope parms, I checked in debug that it was overriding before my call to the program. I have tried this as a straight call in case that was an issue. It is a new program off an existing menu. I see my regular outq of SSPRT is designated in the call, but shouldn't the override do it's job and point the output elsewhere?

    Been playing with this all afternoon, any help would be appreciated. thank you.

    Here is my code and the job log:

    -INC0050C1-------------------------------------------------------------

    PGM PARM(&OUTQ)

    DCL &OUTQ TYPE(*CHAR) LEN(10)


    OVRPRTF FILE(QPQUPRFIL) TOFILE(INR0050F) +
    OUTQ(PGMRSNAPSH) HOLD(*YES) SAVE(*YES)


    CALL PGM(INR0050)


    DLTOVR FILE(QPQUPRFIL)


    RETURN
    ENDPGM



    00 02/18/16 16:16:06.483346 QWTPIIPP QSYS 04C0 *EXT
    Message . . . . : Job 161219/SHARTEST/GRP_MEC started on 02/18/16 at
    16:16:06 in subsystem QBATCH in QGPL. Job entered system on 02/18/16 at
    16:16:06.
    00 02/18/16 16:16:06.483789 QWTPCRJA QSYS 0110 *EXT
    Message . . . . : Job 161219/SHARTEST/GRP_MEC submitted.
    Cause . . . . . : Job 161219/SHARTEST/GRP_MEC submitted to job queue QBATCH
    in QGPL from job 161216/SHARTEST/PGMRSS. Job 161219/SHARTEST/GRP_MEC was
    started using the Submit Job (SBMJOB) command with the following job
    attributes: JOBPTY(5) OUTPTY(5) PRTTXT() RTGDTA(QCMDB) SYSLIBL(QSYS
    QSYS2 QHLPSYS QUSRSYS) CURLIB(*CRTDFT) INLLIBL(SHTSTLIBF SHTSTLIBO
    SYSLIBRF SYSLIBRO PRLIBRF PRLIBRO GLLIBRO GLLIBRF PAYLIBRF
    PAYLIBRO APLIBRF APLIBRO WHSELIBRF ARLIBRF ARLIBRO SPOOLMAIL
    FRTLIBRO FRTLIBRF QGPL GR2000 SALESLIB CCTMLIBO CCTMLIBF)
    INLASPGRP(*NONE) LOG(4 00 *SECLVL) LOGCLPGM(*NO) LOGOUTPUT(*JOBEND)
    OUTQ(QGPL/SSPRT) PRTDEV(PRT01) INQMSGRPY(*RQD) HOLD(*NO) DATE(*SYSVAL)
    SWS(00000000) MSGQ(QUSRSYS/SHARTEST) CCSID(37) SRTSEQ(*N/*HEX) LANGID(ENU)
    CNTRYID(US) JOBMSGQMX(64) JOBMSGQFL(*WRAP) ALWMLTTHD(*NO) SPLFACN(*KEEP)
    ACGCDE().
    02/18/16 16:16:06.484303 QWTSCSBJ *N QCMD QSYS
    Message . . . . : -CALL PGM(INC0050C1) PARM('PGMRPR02')
    00 02/18/16 16:16:06.546720 QWTMCEOJ QSYS 014A *EXT
    Message . . . . : Job 161219/SHARTEST/GRP_MEC ended on 02/18/16 at 16:16:06;
    .025 seconds used; end code 0 .
    Cause . . . . . : Job 161219/SHARTEST/GRP_MEC completed on 02/18/16 at
    16:16:06 after it used .025 seconds processing unit time. The job had
    ending code 0. The job ended after 1 routing steps with a secondary ending
    code of 0. The job ending codes and their meanings are as follows: 0 - The
    job completed normally. 10 - The job completed normally during controlled
    ending or controlled subsystem ending. 20 - The job exceeded end severity
    (ENDSEV job attribute). 30 - The job ended abnormally. 40 - The job ended
    before becoming active. 50 - The job ended while the job was active. 60 -
    The subsystem ended abnormally while the job was active. 70 - The system
    ended abnormally while the job was active. 80 - The job ended (ENDJOBABN
    command). 90 - The job was forced to end after the time limit ended
    (ENDJOBABN command). Recovery . . . : For more information, see the Work
    management topic collection in the Systems management category in the IBM i
    Information Center, http://www.ibm.com/systems/i/infocenter/.


  • #2
    Re: OVRPRTF not working

    What activation groups are your programms (RPG and CL) running in?
    Because I cannot see an override scope explicitly set in your CL program, the default value (which is *ACTGRP) is taken.
    If you perform the override with the default override scope, the override is only valid within the same activation group.
    Assumed your CL program runs in the default activation group and the RPGIV program runs in the QILE (or any other activation group), the override is not considered in the RPG Program.
    Best solution is to set the override scope to *CALLLVL (i.e. Override is valid for the current callstack).

    Birgitta

    Comment


    • #3
      Re: OVRPRTF not working

      Good morning Birgitta, thanks for the help. I changed the submit to a call, and added the *CALLLVL to my OVRPRTF command and it seems to be working. However it generates 2 spool files in the same outq. Here are my changes, please let me know what would cause 2 spool files to generate. Thank you.

      PGM PARM(&OUTQ)

      DCL &OUTQ TYPE(*CHAR) LEN(10)

      OVRPRTF FILE(INR0050F) OUTQ(&outq) HOLD(*YES) +
      SAVE(*YES) OVRSCOPE(*CALLLVL)



      CALL PGM(INR0050)


      DLTOVR FILE(*ALL)

      Comment


      • #4
        Re: OVRPRTF not working

        The 2 spool files was due to me copying a call line in my CL when I was working on the OVRPRTF issue. It is all cleared up now, thanks again for the assistance.

        Comment

        Working...
        X