The command:

Code:

wmic.exe printerconfig get caption /format:table | qgrep.exe -v Caption



Lists all of my printers but I can only run wmic.exe as administrator.

One thing that I did notice is that it is exiting in the IF statement in the PrinterList() function:

Code:


$Service = GetObject("winmgmts:\\" + $remotepc + "\root\cimv2")
If @error
? "Errors dicovered. " + @ERROR
Exit @error
EndIf



It's returning error code: -2147024891