By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
443,534 Members | 943 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 443,534 IT Pros & Developers. It's quick & easy.

WMI for Printer Status??

P: n/a
I'm trying to grab printer status for a printer with WMI

I got a mo("PrinterState").tostring of "128" for a paused HP printer. What
is "128" equate to? It did give a mo("PrinterStatus").tostring of 1 =
"paused" which was correct but it took a while to display the correct state.

When I un-paused the printer, I got a mo("PrinterState").tostring of "0".
What is "0" equate to? It got a mo("PrinterStatus").tostring of 0. Is "0"
mean ok, ready?

Anyone had experience in correctly grabbing info from WMI?

I'm getting info but not consistent info and i don't know how to translate
the codes since they don't match up with the ones in the WMI SDK.
Any clues as how to effectively use
Management.ManagementObjectSearcher("Select * from Win32_Printer")

to get accurate info on networked printers within a domain?

TIA

Harry
Nov 20 '05 #1
Share this Question
Share on Google+
2 Replies


P: n/a
I don't know the answer, but you might try posting in
microsoft.public.dotnet.fromework.wmi newsgroup

Good Luck

"Harry Simpson" <hs*******@nospamphgt.net> wrote in message
news:ew**************@tk2msftngp13.phx.gbl...
I'm trying to grab printer status for a printer with WMI

I got a mo("PrinterState").tostring of "128" for a paused HP printer. What
is "128" equate to? It did give a mo("PrinterStatus").tostring of 1 =
"paused" which was correct but it took a while to display the correct state.
When I un-paused the printer, I got a mo("PrinterState").tostring of "0".
What is "0" equate to? It got a mo("PrinterStatus").tostring of 0. Is "0" mean ok, ready?

Anyone had experience in correctly grabbing info from WMI?

I'm getting info but not consistent info and i don't know how to translate
the codes since they don't match up with the ones in the WMI SDK.
Any clues as how to effectively use
Management.ManagementObjectSearcher("Select * from Win32_Printer")

to get accurate info on networked printers within a domain?

TIA

Harry

Nov 20 '05 #2

P: n/a
I don't know the answer, but you might try posting in
microsoft.public.dotnet.fromework.wmi newsgroup

Good Luck

"Harry Simpson" <hs*******@nospamphgt.net> wrote in message
news:ew**************@tk2msftngp13.phx.gbl...
I'm trying to grab printer status for a printer with WMI

I got a mo("PrinterState").tostring of "128" for a paused HP printer. What
is "128" equate to? It did give a mo("PrinterStatus").tostring of 1 =
"paused" which was correct but it took a while to display the correct state.
When I un-paused the printer, I got a mo("PrinterState").tostring of "0".
What is "0" equate to? It got a mo("PrinterStatus").tostring of 0. Is "0" mean ok, ready?

Anyone had experience in correctly grabbing info from WMI?

I'm getting info but not consistent info and i don't know how to translate
the codes since they don't match up with the ones in the WMI SDK.
Any clues as how to effectively use
Management.ManagementObjectSearcher("Select * from Win32_Printer")

to get accurate info on networked printers within a domain?

TIA

Harry

Nov 20 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.