Sign up for the ITPro Today newsletter
Stay on top of the IT universe with commentary, news analysis, how-to's, and tips delivered to your inbox daily.
Quickly check the parameters expected by a PowerShell script.
March 12, 2015
Q. How can I quickly check in PowerShell what parameters a script expects?
A. One way is to simply open the PowerShell script and examine the code, but there's an even easier way:
help .This will output the parameters and the types expected. An example is shown below which demonstrates the script expects a string value to be passed.PS C:> help .checkos.ps1 -Fullcheckos.ps1 [[-computername] ]
You May Also Like