how to query printer status thru code?
Hi,
Can someone tell me how to query the status of a printer, attached/ connected to one's desktop, thru code.?
I need to find out if the printer my application is trying to print to, is valid/ offline/ ... before attempting to print, to save on parsing log files, to find out why the print job did not print.
Parsing Log files, may look a small job, but for my application they are huge - 16Kb and higher.
Any clues, in VB/ VC/Win SDK will be appreciated, as I dont know MFC and Java.
regards
Jeevan
Re: how to query printer status thru code?
the printer status can be obtained from the PRINTER_INFO_2 structure (field "Status") using the GetPrinter API function (sorry, don't have a VB solution).