Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Win API spooler functions usage

Status
Not open for further replies.

hiptino

Programmer
May 27, 2000
18
0
0
NG
I'm currently writing a Printer Monitor software with VB6.<br>I employed two Win API spooler functions, Enumjobs() and GetPrinter().<br>These two functions returns a status member which can be used to determine the status of a printjob and the printer.<br><br>I tested the software, the JOB_INFO_2 status memmber was able to detect the status of the printjob when it's printing,spooling or paused. Also the PRINTER_INFO_2 status member was able to get the status of the printer when it is paused. But the PRINTER_INFO_2 status member could not determine the status of the printer when there is a paperjam, paperout,printing and other possible status, when I intentionally create those(paperout,paperjam..)situations. Likewise if there is a successful printing, the JOB_INFO_2 status member does not indicate "JOB_STATUS_PRINTED".<br><br>I could not find a clue as to the cause of this problem.<br>I used printers HP1120C, HP895cxi, OKIPAGE3+ and Win98, WinNT 4.0 for the test.<br>Could it be that the Enumjobs() and Getprinter() APIs are obsolete.<br>Or could it be that the these constants<br>(Public Const PRINTER_STATUS_PAPER_JAM = &H8)<br>(Public Const PRINTER_STATUS_PAPER_OUT = &H10)..etc<br>are no longer supported.<br><br>Please, I would appreciate any suggestion you have. This particular problem has been delaying my project.<br><br>Thank you,
 
What is the purpose of this Monitor program?<br>If you are on a network there are network resources already in place to notify users of Printer problems.<br>You just have to implement them.<br><br> <p>DougP<br><a href=mailto: dposton@universal1.com> dposton@universal1.com</a><br><a href= > </a><br> Ask me how Bar-codes can help you be more productive.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top