Home » PowerShell » Get Printer Configuration in Windows Using PowerShell

Get Printer Configuration in Windows Using PowerShell

Use the `Get-PrintConfiguration` command in PowerShell to get printer configuration in Windows. This command gets the configuration information about the specified printer.

Here is the PowerShell command that retrieves the printer configuration in Windows.

Get-PrintConfiguration
   [-ComputerName <String>]
   [-PrinterName] <String>
   [-CimSession <CimSession[]>]
   [-ThrottleLimit <Int32>]
   [-AsJob]
   [<CommonParameters>]

The Get-PrinterConfiguration command can be used to manage the configuration of the features such as:

  • Collate
  • Color
  • Duplexing Mode
  • N-Up
  • Paper Size

In this article, we will discuss how to use the Get-PrintConfiguration command in PowerShell to get the printer configuration and get the printer configuration for all printers.

How to Get the Printer Configuration

To get the printer configuration for the specified printer in Windows, use the Get-PrintConfiguration command.

Get-PrintConfiguration -PrinterName "\\incorp-eu1-01\HP_Printer"

In the above PowerShell script, the Get-PrinterConfiguration command uses the PrinterName parameter to specify the name of the printer and return the printer configuration information.

The output of the above PowerShell script that checks the printer configuration and retrieves the information is given below.

Get Printer Configuration Information in PowerShell
Get Printer Configuration Information in PowerShell

The Get-PrinterConfiguration command returns the printer properties such as Collate, Color and DuplexingMode.

How to Get the Printer Configuration for All Printers

To get the printer configuration for all printers, use the Get-PrintConfiguration cmdlet in PowerShell.

# Get list of printers
$Printers = Get-Printer *

# Iterate each printer in the list and retrieve the printer configuration
Foreach ($printer in $Printers){
    Get-PrintConfiguration -PrinterName $printer.name
}

In the above PowerShell script, the Get-Printer * command gets a list of all printers and stores it in a variable $Printers. The Foreach loops through all the printers and gets the configuration for the printer and displays their properties.

Conclusion

I hope the above article on how to get printer configuration information using the PowerShell Get-PrintConfiguration command is helpful to you.

You can find more topics about PowerShell Active Directory commands and PowerShell basics on the ShellGeek home page.