Spooler Plus Programmer's Guide

Spooler Procedure Calls
Spooler Plus Programmers Guide522293-003
4-9
PRINTREAD Procedure
PRINTREAD Procedure
The PRINTREAD procedure can be used in print and perusal processes to access
spooled data and to allow print processes to communicate with the spooler supervisor.
This includes spooler data stored in a spooler job file.
The PRINTREAD procedure returns one line of spooled data.
error-code returned value
INT
returns a spooler error code. Certain nonzero error-codes from PRINTREAD
have special significance:
See Appendix C, Spooler-Related Errors, for a list of spooler errors and their
meanings.
job-buffer input, output
INT:ref:560
is the job buffer for the job being read.
data-line output
INT:ref:450 (or less)
error-code := PRINTREAD ( job-buffer ! i,o
,data-line ! o
,read-count ! i
,[ count-read ] ! o
,[ pagenum ] ); ! i
%1200
0
End of file. All lines in the job have been transferred (send an “end
job” message to the supervisor by PRINTSTATUS; this error is
returned only for print processes—not for perusal processes).
%1200
1
End of copy.
%1200
2
Invalid data file.
%1200
3
CONTROL found.
%1200
4
SETMODE found.
%1200
5
CONTROLBUF found.