GetJob
The GetJob
function retrieves print-job data for the specified printer.
BOOL GetJob(
HANDLE hPrinter, |
// handle of
printer |
DWORD JobId, |
// job identifier
value |
DWORD Level, |
// data-structure
level |
LPBYTE pJob, |
// address of
data-structure array |
DWORD cbBuf, |
// count of bytes
in array |
LPDWORD pcbNeeded |
// address of value
that contains count of bytes retrieved (or required) |
); |
|
Parameters
hPrinter
Identifies
the printer for which the print-job data is retrieved.
JobId
Identifies
the print job for which data should be retrieved.
Level
Specifies the
level of the structure to which pJob points. This value must be either 1
or 2.
pJob
Points to an
array that contains either a JOB_INFO_1
cbBuf
Specifies the
size, in bytes, of the array.
pcbNeeded
Points to a
value that specifies the number of bytes copied if the function succeeds or the
number of bytes required if cbBuf is too small.
Return Values
If the
function succeeds, the return value is nonzero.
If the
function fails, the return value is zero. To get extended error information,
call GetLastError
See Also