Please enable JavaScript to view this site.

The Cobwebb Print exit programs can be used in the Print Output Device and are used mainly to automate the print attributes. Sample programs may be found in either the USRTOOL [for RPG] or USRTOOLLE [for RPGLE] source file in the CPPD library - see entries where the Description is prefixed OUTD-PRT. You can use CLLE (or CLP) as well but you must have all the correct parameters as defined below.

Note: When creating an Print Exit Program you will need to add any required libraries (before you open the files) as the libraries added to your Cobwebb Design are not carried through to the Distribution program.

Step 1 - Create your Cobwebb Print Exit Program
Notes:
The first parameter will always be the Input string; all of the other parameters may be used to pass back information to your Cobwebb Design.
Remember to set the Error parameter to either 0 (or blank) for Success or 1 for Failure this is then passed back to the Cobwebb Server software to handle accordingly.

Step 2 - Test your Cobwebb Print Exit Program using the Cobwebb Test Harness for a File Exit Program TSTPPRM.

Step 3 - Test your PPD interactively.

oEnable Test Mode to write parameter details to the joblog.

oUse the RUNPPD command. Note: Make sure that you only have the libraries that existing in the SPLMON Job Description in your Library List (CPPD, QGPL, QTEMP by default) so if there are any missing libraries you will know and can add them to your Print Exit Program.

Program Parameters

Parameter

Attribute

Description

Input

A (256)

Input string - Destination Address element

OutQNam

A (10)

Output Queue Name

OutQLib

A (10)

Output Queue Library

OutDev

A (10)

Output Device Name

FormType

A (10)

Forms Type

UserData

A (10)

User Data

HoldPrt

A (4)

Hold Print

SavePrt

A (4)

Save Print

Duplex

A (7)

Duplex

Drawer

A (5)

Drawer

Copies

Z (3,0)

Number of copies

Error

A (1)

Error code to return to calling program.

0 = Success

1 = Failure