The GetJobID method returns the print job ID of the job that the printing to the passed in DC parameter if still valid.
System.Int32 GetJobID(System.IntPtr hDC)
int GetJobID(HANDLE hPrinter, HDC hdc)
hDC
Handle to printer device context returned by a call to CreateDC or by the application.
hPrinter
Handle to printer returned by any of the DriverInit function calls.
This method returns job ID.
Member of CDIntfEx.CDIntfEx.