You are on page 1of 1

strComputer = "." Set objWMIService = Getobject("winmgmts:" _ & "{impersonationLevel=impersonate}!\\" & strComputer & "\root\cimv2") Set colInstalledPrinters = objWMIService.

ExecQuery _ ("SELECT * FROM win32_Printer WHERE NOT DeviceID LIKE '%PDF%'") For Each objPrinter in colInstalledPrinters 'objPrinter.Delete_ Wscript.echo objPrinter.DeviceID Next

You might also like