Get-PrintConfiguration

Get-PrintConfiguration

Gets the configuration information of a printer.

構文

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

Parameter Set: PrinterObject
Get-PrintConfiguration [-PrinterObject] <CimInstance> [-AsJob] [-CimSession <CimSession[]> ] [-ThrottleLimit <Int32> ] [ <CommonParameters>]

詳細説明

The Get-PrintConfiguration cmdlet gets the configuration information of the specified printer. Using Get-PrintConfiguration cmdlet, you can manage the configuration of the following features:

● Collate

● Color

● Duplexing Mode

● N-Up

● Paper Size

You cannot use wildcard characters with Get-PrintConfiguration. You can use Get-PrintConfiguration in a Windows PowerShell remoting session.

You do not need administrator privileges to use Get-PrintConfiguration.

パラメーター

-AsJob

エイリアス

なし

必須?

false

位置は?

named

既定値

なし

パイプライン入力を許可する

false

ワイルドカード文字を許可する

false

-CimSession<CimSession[]>

リモート セッションまたはリモート コンピューターでコマンドレットを実行します。New-CimSession コマンドレットや Get-CimSession コマンドレットの出力など、コンピューター名またはセッション オブジェクトを入力します。既定値は、ローカル コンピューターで実行中の現在のセッションです。

エイリアス

Session

必須?

false

位置は?

named

既定値

なし

パイプライン入力を許可する

false

ワイルドカード文字を許可する

false

-ComputerName<String>

Specifies the name of the computer from which to retrieve the printer configuration information.

エイリアス

Computer,CN

必須?

false

位置は?

named

既定値

なし

パイプライン入力を許可する

True (ByValue, ByPropertyName)

ワイルドカード文字を許可する

false

-PrinterName<String>

Specifies the name of the printer from which to retrieve the configuration information.

エイリアス

PN

必須?

true

位置は?

1

既定値

なし

パイプライン入力を許可する

True (ByValue, ByPropertyName)

ワイルドカード文字を許可する

false

-PrinterObject<CimInstance>

Specifies the object which contains the printer from which to retrieve configuration information.

エイリアス

Printer

必須?

true

位置は?

1

既定値

なし

パイプライン入力を許可する

True (ByValue, ByPropertyName)

ワイルドカード文字を許可する

false

-ThrottleLimit<Int32>

このコマンドレットを実行するために確立できる最大同時操作数を指定します。このパラメーターを省略するか、値として 0 を入力した場合、Windows PowerShell® では、コンピューターで実行している CIM コマンドレットの数に基づいて、コマンドレットに対する最適なスロットル制限を計算します。スロットル制限は現在のコマンドレットのみに適用され、セッションまたはコンピューターには適用されません。

エイリアス

なし

必須?

false

位置は?

named

既定値

なし

パイプライン入力を許可する

false

ワイルドカード文字を許可する

false

<CommonParameters>

このコマンドレットは次の共通パラメーターをサポートします。-Verbose、-Debug、-ErrorAction、-ErrorVariable、-OutBuffer、-OutVariable.詳細については、以下を参照してください。 about_CommonParameters (https://go.microsoft.com/fwlink/p/?LinkID=113216)。

入力

入力型は、コマンドレットにパイプできるオブジェクトの型です。

  • Microsoft.Management.Infrastructure.CimInstance#ROOT/StandardCimv2/MSFT_Printer

    This cmdlet accepts one printer object.

出力

出力型は、コマンドレットによって生成されるオブジェクトの型です。

  • Microsoft.Management.Infrastructure.CimInstance#MSFT_PrinterConfiguration

    This cmdlet returns a printer configuration object.

Example 1: Get the printer configuration

This command returns the printer configuration for the printer named "Microsoft XPS Document Writer".

PS C:\> Get-PrintConfiguration –PrinterName "Microsoft XPS Document Writer"

Example 2: Get the print configuration for all printers

This command gets all the printers into a variable $printers and then loops through all the printers and displays the properties.

PS C:\> $printers = get-printer * foreach ($printer in $printers){     Get-printconfiguration –printerName $printer.name –duplexingMode “TwoSidedLongEdge”}

関連トピック

Set-PrintConfiguration