Using a generic override for printer files

The OVRPRTF command allows you to have one override for all the printer files in your job with the same set of values. Without the generic override, you would have to do a separate override for each of the printer files.

Applying OVRPRTF with *PRTF: scenario

You can apply the OVRPRTF command to all printer files by specifying *PRTF as the file name.

The OVRPRTF command with *PRTF is applied if there is no other override for the printer file name at the same call level. The following example shows how *PRTF works:




Override 1 OVRPRTF FILE(OUTPUT) COPIES(6) +


LPI(6)
Override 2 OVRPRTF FILE(*PRTF) COPIES(1) +
LPI(8)
CALL PGM(X)

When program X opens the file OUTPUT, the opened file has the following attributes:

COPIES(6)
From Override 1

LPI(6)
From Override 1

When program X opens the file PRTOUT (or any printer file other than OUTPUT), the opened file has the following attributes:

COPIES(1)
From Override 2

LPI(8)
From Override 2

Applying OVRPRTF with *PRTF from multiple call levels: scenario

The following example shows how printer-file overrides are applied from multiple call levels by using the *PRTF value.




Program A
Override 1 OVRPRTF FILE(*PRTF) COPIES(1)
Override 2 OVRPRTF FILE(PRT2) COPIES(2)
Override 3 OVRPRTF FILE(PRT4) COPIES(2)
CALL PGM(B)


Program B
Override 4 OVRPRTF FILE(*PRTF) LPI(4)
Override 5 OVRPRTF FILE(PRT3) LPI(8)
Override 6 OVRPRTF FILE(PRT4) LPI(8)
CALL PGM(X)

When program X opens the file PRT1, the opened file has the following attributes:

COPIES(1)
From Override 1

LPI(4)
From Override 4

Because no specific overrides are found for PRT1, *PRTF overrides (1 and 4) are applied.

When program X opens the file PRT2, the opened file has the following attributes:

COPIES(2)
From Override 2

LPI(4)
From Override 4

Because no specific override is found for PRT2 in program B, override 4 is applied. In program A, override 2 specifies PRT2 and is applied.

When program X opens the file PRT3, the opened file has the following attributes:

COPIES(1)
From Override 1

LPI(8)
From Override 5

In program B, override 5 specifies PRT3 and is applied. Because no specific override is found for PRT3 in program A, override 1 is applied.

When program X opens the file PRT4, the opened file has the following attributes:

COPIES(2)
From Override 3

LPI(8)
From Override 6

In program B, override 6 specifies PRT4 and is applied. In program A, override 3 specifies PRT4 and is applied.


[ Top of Page | Previous Page | Next Page | Table of Contents | Index ]