Using PowerShell to list installed printers

by Mitch Tulloch [Published on 22 Oct. 2014 / Last Updated on 22 Oct. 2014]

This tip shows how you can use Windows PowerShell to retrieve a list of printers installed on a print server.

You can use the Get-Printer cmdlet to display a list of the installed printers on a print server. For example, the following command shows that there are four printers installed on a remote print server named HOST7:

PS C:\> Get-Printer -ComputerName HOST7 | Format-List Name,DriverName

Name      
: Samsung CLP-410 Series PCL6
DriverName : Samsung CLP-410 Series PCL6

Name      
: HP LaserJet 4200L PCL6
DriverName : HP LaserJet 4200L PCL6 Class Driver

Name      
: Microsoft XPS Document Writer
DriverName : Microsoft XPS Document Writer v4

Name      
: HP LaserJet 5200 PCL6
DriverName : HP LaserJet 5200 PCL6 Class Driver

You can pipe the output from the preceding command into the Where-Object cmdlet to determine which of these printers are shared:

PS C:\> Get-Printer -ComputerName HOST7 | where Shared -eq $true | fl Name

Name : Samsung CLP-410 Series PCL6
Name : HP LaserJet 4200L PCL6
Name : HP LaserJet 5200 PCL6

The above tip was excerpted from Mitch Tulloch's book Training Guide: Installing and Configuring Windows Server 2012 from Microsoft Press.

Mitch is a nine-time recipient of the Microsoft Most Valuable Professional (MVP) award and a widely recognized expert on Windows administration, deployment and virtualization.  For more information see http://www.mtit.com.

See Also


The Author — Mitch Tulloch

Mitch Tulloch is a well-known expert on Windows Server administration and cloud computing technologies. He has published over a thousand articles on information technology topics and has written, contributed to or been series editor for over 50 books.