HDC gdiPlaySpoolStream(
LPSTR lpszDevice,
LPSTR lpszOutput,
LPSTR lpszSpoolFile,
DWORD JobId,
LPDWORD lpcbBuf,
HDC hDC
);
The Microsoft-provided GDI 32 gdiPlaySpoolStream function plays back a spool file or a buffer of spool data, or deletes all the EMFs of a spool file.
lpszDevice | Specifies the name of the printer that prints the document, or NULL. If NULL, gdiPlaySpoolStream deletes all the .TMP files whose paths are listed in the job description file specified by the lpszSpoolFile parameter. |
lpszOutput | Output file name from StartDoc, that will be passed back into StartDoc. |
lpszSpoolFile | Spool file name or a buffer of spool data depending on the value in the lpcbBuf parameter. |
JobId | Identifies the print job. |
lpcbBuf | If lpcbBuf is NULL, lpszSpoolFile is a spool file name and this parameter is not used. |
If lpcbBuf is non-NULL, lpszSpoolFile is a buffer of spool data and lpcbBuf points to the size of the buffer. Upon return, lpcbBuf points to the amount of data (number of bytes) in the buffer that was processed, since the buffer may not end at a spool data block boundary. | |
hDC | If the lpcbBuf parameter is NULL, the hDC parameter is not used by the gdiPlaySpoolStream function. |
If the lpcbBuf parameter is non-NULL, the hDC parameter specifies the handle of the DC used to play back the spool buffer. If the lpcbBuf parameter is non-NULL and the hDC parameter is NULL, the very first buffer of the job is being played and there is not a valid handle to a DC yet. |
If lpcbBuf is NULL, lpszSpoolFile points to the file name of the spool file to playback. Otherwise, lpszSpoolFile is the pointer to a buffer of spool data, and lpcbBuf points to the size of the buffer and upon return, lpcbBuf points to the number of bytes that were actually sent to the printer.
If the hDC parameter is NULL, then this is the first call made to play the spool file. Otherwise, the hDC parameter will contain the handle of the DC that gdiPlaySpoolStream will use to play the remainder of the spool file.