Re: Discover local printers in SMS 2003
- From: "David Ferentheil" <ferenthd@xxxxxxxxxx>
- Date: 18 Jan 2006 13:39:17 -0800
Network printers are associated with the user, not the computer. To
associate with the computer,
Create local printer (Not Network)
for the port create either
1) IP port to Printer
2) Local port to \\printservername\share
jeff wrote:
> OOPPPSS, wrong script, this one;
>
> strComputer = "."
> Set objWMIService = GetObject("winmgmts:" _
> & "{impersonationLevel=impersonate}!\\" & strComputer & "\root\cimv2")
>
> Set colInstalledPrinters = objWMIService.ExecQuery _
> ("Select * from Win32_Printer")
>
> For Each objPrinter in colInstalledPrinters
> Wscript.Echo "Name: " & objPrinter.ServerName
> Wscript.Echo "Name: " & objPrinter.ShareName
> Wscript.Echo "Name: " & objPrinter.Name
> Wscript.Echo "Location: " & objPrinter.Location
> Wscript.Echo "Default: " & objPrinter.Default
> Next
>
> "jeff" wrote:
>
> >
> > I'm sure thats fine, this script run local produces a accurate list of all
> > defined printers;
> >
> > strComputer = "."
> > Set objWMIService = GetObject("winmgmts:" _
> > & "{impersonationLevel=impersonate}!\\" & strComputer & "\root\cimv2")
> >
> > Set colInstalledPrinters = objWMIService.ExecQuery _
> > ("Select * from Win32_Printer")
> >
> > For Each objPrinter in colInstalledPrinters
> > Wscript.Echo "Name: " & objPrinter.Name
> > Wscript.Echo "Location: " & objPrinter.Location
> > Wscript.Echo "Default: " & objPrinter.Default
> > Next
> >
> >
> > "Kim Oppalfens <MVP>" wrote:
> >
> > > have you tried verifying whether the data is accurate in wmi?
> > >
> > > --
> > > Kim Oppalfens
> > > Telindus Belgium
> > > MVP Windows Server System - SMS
> > > "jeff" <jeff@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
> > > news:5FA4744A-DA3D-4433-8512-D8F9FB0FEB0E@xxxxxxxxxxxxxxxx
> > > >I guess I'm not being clear, SMS is not collecting the data for servername
> > > > at all and the sharename data is blank, according to this page;
> > > > http://www.microsoft.com/technet/prodtechnol/sms/sms2/reskit/appendixes/smapc.mspx
> > > > I don't even need the servername data as the sharename data reports as;
> > > > "\\\\PRINTSERVER1\\PRINTER2"
> > > >
> > > > But the data is just not there at all, I'm getting on I need on local
> > > > attached printers, even direct IP printers, just nothing on network
> > > > printers.
> > > >
> > > >
> > > > "Kim Oppalfens <MVP>" wrote:
> > > >
> > > >> Create a report for all printers that do not have a Caption that start
> > > >> with
> > > >> a \
> > > >>
> > > >>
> > > >>
> > > >> --
> > > >> Kim Oppalfens
> > > >> Telindus Belgium
> > > >> MVP Windows Server System - SMS
> > > >> "jeff" <jeff@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
> > > >> news:D40641DC-CA22-4760-B597-251109CD41A6@xxxxxxxxxxxxxxxx
> > > >> > Hi Kim, I've modified the MOF to report these items to SMS;
> > > >> > Caption,
> > > >> > Drivername,
> > > >> > Name,
> > > >> > PortName
> > > >> > Servername
> > > >> > Sharename
> > > >> >
> > > >> > And all are showing up except servername when I go to create a
> > > >> > collection
> > > >> > or
> > > >> > Query. Could you give me a direstion that I should go in resolving
> > > >> > this?
> > > >> >
> > > >> >
> > > >> > "Kim Oppalfens <MVP>" wrote:
> > > >> >
> > > >> >> Do you only want to inventorize local printers?
> > > >> >> Or do you want a seperate report with only local printers?
> > > >> >> Eitherway I would filter on deviceid not starting with \
> > > >> >>
> > > >> >> --
> > > >> >> Kim Oppalfens
> > > >> >> Telindus Belgium
> > > >> >> MVP Windows Server System - SMS
> > > >> >> "Takis" <p.kalfakakos@xxxxxxx> wrote in message
> > > >> >> news:ueriXO0GGHA.3916@xxxxxxxxxxxxxxxxxxxxxxx
> > > >> >> > Any idea on how to discover local printers attached on clients PCs
> > > >> >> > ???????????
> > > >> >> >
> > > >> >> >
> > > >> >> > Thanks
> > > >> >> >
> > > >> >>
> > > >> >>
> > > >> >>
> > > >>
> > > >>
> > > >>
> > >
> > >
> > >
.
- Follow-Ups:
- Re: Discover local printers in SMS 2003
- From: jeff
- Re: Discover local printers in SMS 2003
- References:
- Discover local printers in SMS 2003
- From: Takis
- Re: Discover local printers in SMS 2003
- From: jeff
- Re: Discover local printers in SMS 2003
- From: jeff
- Discover local printers in SMS 2003
- Prev by Date: Re: Unable to retrieve AD site membership
- Next by Date: Re: Discover local printers in SMS 2003
- Previous by thread: Re: Discover local printers in SMS 2003
- Next by thread: Re: Discover local printers in SMS 2003
- Index(es):
Relevant Pages
|