[python-win32] Printer Response
Tim Roberts
timr at probo.com
Sun Jan 31 20:53:29 EST 2016
On Jan 30, 2016, at 3:31 PM, Malik Brahimi <mbrahimi02 at gmail.com> wrote:
>
> I've been looking through the win32print API but I do not believe that all the Windows features are fully exposed in this package. Is there a way for me to trigger a callback function once the print server or USB printer receives a print job such that I can obtain that print job's id?
The Windows printing APIs are steeped in the mists of antiquity and mired in backward compatibility much, and are generally among the least well designed in the API set.
I’m not sure what you are expecting to get. What do you think that a print job ID looks like, and what do you think you will be able to do with it? Remember that it’s quite possible to configure a Windows printer without the spooler, so that jobs go straight to the printer. In that case, there will never be an ID of any kind.
You can certainly use win32print.StartDocPrinter, and that does return an identifier, but I don’t know what good that does you.
—
Tim Roberts, timr at probo.com
Providenza & Boekelheide, Inc.
More information about the python-win32
mailing list