Getting Help on a Powershell Command: Get-Command

Get-Command can provide you with details on the Powershell commands available to you in a particular instance.

So if you know the Powershell command (Verb-Noun) that you are needing to use but struggling with the format or parameters, you can execute the following to get help with the command:

(Get-Command CommandName).parameters

Examples:

If you are trying to get the parameters used for the New-CMDeviceCollection command using Powershell with Configuration Manager (SCCM), the get command would be:

(Get-Command New-CMDeviceCollection).parameters


If you want to know all the Powershell commands that start with S:
Get-Command S*


If you want to know what parameters are used with the Powershell command Suspend-Service
(Get-Command Suspend.Service).parameters