Windows API for detecting paper on a specific printer tray

I’m looking for a way to determine if there is paper on a particular tray on this printer in Windows. Currenly I use the Win32_Printer WMI object to get the status of the entire printer, and if one of the trays is out of paper, I get a status that tells me that the whole printer is out of paper.

But I would like to know if there is paper in a separate tray. The copied Google searches didn’t come up with anything.

I am writing an application in C #, but pointers to examples in any language will do.

Thanks in advance..

+4
source share
2 answers

This is because they are usually hardware specific interfaces. If you use a single hardware vendor, such as HP or Dell, then you are likely to find a way to figure this out. But the Windows interface, apparently, only allows notification of a complete absence of a printer.

+1
source

I did not do this, but it seems I remember that you can do this through SNMP.

0
source

All Articles