The WinprintPrintDocumentOnPrintProcessor function uses two data structures: PRINTPROCESSORDOCUMENTDATA, a pointer to which is given as a parameter, and the global PRINTPROCESSORDATA structure.
typedef struct _PRINTPROCESSORDOCUMENTDATA
{
LPDEVMODE pDevMode; // printer device init and status info
LPTSTR pDatatype; // datatype of document
LPTSTR pParameters; // print processor parameters
LPTSTR pDocumentName; //
DWORD JobId; // print job assoc w/ document
LPTSTR pOutputFile; // document spool file
LPTSTR pSpoolFileName; // full path to document spool file
LPTSTR pSepFile; // file printed between jobs
}PRINTPROCESSORDOCUMENTDATA
The global PRINTPROCESSORDATA structure is defined below:
typedef struct _PRINTPROCESSORDATA
{
DWORD signature;
DWORD cb;
struct _PRINTPROCESSORDATA FAR *pNext;
DWORD fsStatus;
HANDLE semPaused;
DWORD uDatatype;
HANDLE hPrinter;
LPTSTR pPrinterName;
} PRINTPROCESSORDATA, *PPRINTPROCESSORDATA;