Parameter values

Value types of arguments (the type of value expected by a parameter) are enclosed in angular brackets, as shown in the following example:

<string> 
<string[]> 

If a value is in the <string> form, a single value is expected. If the value is in the <string[]> form, an array (or list) of values is expected.

For example, Get-CimInstance accepts a single value only for the ClassName parameter:

SYNTAX
Get-CimInstance [-ClassName] <String> ...

The command may be called as follows:

Get-CimInstance -ClassName Win32_OperatingSystem 

In comparison, Get-Process accepts multiple values for the Name parameter:

SYNTAX
Get-Process [[-Name] <String[]>] ...

Get-Process may be called as follows:

Get-Process -Name powershell, explorer, smss 
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
13.59.122.162