Ureader.com  
Microsoft software help and Community
   home   |   control panel login   |   archive   |  
 
Windos
win32.3rdparty
win32.directx.audio
win32.directx.ddk
win32.directx.graphics
win32.directx.input
win32.directx.managed
win32.directx.misc
win32.directx.networking
win32.directx.sdk
win32.directx.video
win32.dirx.grap.shaders
win32.gdi
win32.international
win32.kernel
win32.messaging
win32.mmedia
win32.networks
win32.ole
win32.rtc
win32.tapi
win32.tapi.beta
win32.tools
win32.ui
win32.wince
win32.wmi
windows.mediacenter
winfx.aero
winfx.announcements
winfx.avalon
winfx.collaboration
winfx.fundamentals
winfx.general
winfx.indigo
winfx.sdk
winfx.winfs
  
 
date: Thu, 3 Apr 2008 02:00:00 -0700,    group: microsoft.public.win32.programmer.gdi        back       


Need Printer Details   
Hi All,

I want to get details of printer like vendor, product, serial no., IP 
address(for N/W printers) and MAC address.

I have seen Win Spooler APIs like GetPrinter(), EnumPrinter() and 
PRINTER_INFO_2 structure, however none of them gives above mentioned 
parameters.

Above mentioned attributes are vailable in registry, but as registry can not 
reliable source to get theses details with consistency it is not ood option.

Can we get these details from printer or any other source.
Please let me know which win API or windows method I need to use for this 
purpose.

Thanks,
Ajay
date: Thu, 3 Apr 2008 02:00:00 -0700   author:   Ajay Shinde

Re: Need Printer Details   
The Win32_Printer WMI class may get you some of that information.

Mark

-- 
Mark Salsbery
Microsoft MVP - Visual C++


"Ajay Shinde"  wrote in message 
news:C662A8C9-B2F0-4482-8244-36375A89FD07@microsoft.com...
> Hi All,
>
> I want to get details of printer like vendor, product, serial no., IP
> address(for N/W printers) and MAC address.
>
> I have seen Win Spooler APIs like GetPrinter(), EnumPrinter() and
> PRINTER_INFO_2 structure, however none of them gives above mentioned
> parameters.
>
> Above mentioned attributes are vailable in registry, but as registry can 
> not
> reliable source to get theses details with consistency it is not ood 
> option.
>
> Can we get these details from printer or any other source.
> Please let me know which win API or windows method I need to use for this
> purpose.
>
> Thanks,
> Ajay
>
date: Thu, 3 Apr 2008 09:42:59 -0700   author:   Mark Salsbery [MVP] MarkSalsbery[MVP]@newsgroup.nospam

Re: Need Printer Details   
Thanks mark for your reply.

I verified Win32_Printer class details.
Using this class we can identify whether printer is local printer or N/W 
printer.
Details like vendor, product, serial no., IP address(for N/W printers) and 
MAC address are not available in this class.
I verified other classes like Win32_PrinterController, 
Win32_PrinterConfiguration, Win32_PrinterDriver also but required details are 
not available.

Any idea to get these details.

I shall try with Win32_TCPIPPrinterPort to see whether we can have IP 
address(for N/W printers) and MAC address.

Please suggest.

Thanks,
Ajay




"Mark Salsbery [MVP]" wrote:

> The Win32_Printer WMI class may get you some of that information.
> 
> Mark
> 
> -- 
> Mark Salsbery
> Microsoft MVP - Visual C++
> 
> 
> "Ajay Shinde"  wrote in message 
> news:C662A8C9-B2F0-4482-8244-36375A89FD07@microsoft.com...
> > Hi All,
> >
> > I want to get details of printer like vendor, product, serial no., IP
> > address(for N/W printers) and MAC address.
> >
> > I have seen Win Spooler APIs like GetPrinter(), EnumPrinter() and
> > PRINTER_INFO_2 structure, however none of them gives above mentioned
> > parameters.
> >
> > Above mentioned attributes are vailable in registry, but as registry can 
> > not
> > reliable source to get theses details with consistency it is not ood 
> > option.
> >
> > Can we get these details from printer or any other source.
> > Please let me know which win API or windows method I need to use for this
> > purpose.
> >
> > Thanks,
> > Ajay
> >
date: Tue, 8 Apr 2008 06:34:00 -0700   author:   Ajay Shinde

Google
 
Web ureader.com


    COPYRIGHT 2007, YARDI TECHNOLOGY LIMITED, ALL RIGHT RESERVE  |   contact us