APC Australia

Get help

-

There’s plenty of help — offline and on — waiting for you with PowerShell. The obvious place to start is with its own built-in help tools. Type the following: > help cmdlet Replace ‘cmdlet’ with your cmdlet’s or alias’s name. You’ll receive a prompt that the more detailed help files require installing, but to avoid a string of error messages, first close and restart PowerShell as an administra­tor, then type: > Update-Help A green progress bar appears, and then the files are added, one module at a time — don’t be surprised to end with an error message or two, which can be safely ignored. Close and restart PowerShell again.

Now the help files have been replaced, use the following command: > Get-Help cmdlet You can add some handy parameters: ‘-detailed’ (‘Get-Help cmdlet -detailed’) provides a list of all available parameters for that cmdlet, plus examples of them in action. Use ‘-examples’ if you only want to view examples. One downside of the help file is that you need to keep scrolling back to reference it; add ‘-online’ and it opens in your browser, enabling you to view it side-by-side while coding.

You’ll also find lots of websites providing you with more help and advice, too. One of our favourites can be found at www.computer performanc­e.co.uk/powershell — although written for an older version of PowerShell, its basic advice holds true, and it provides a good reference guide, with a handy, if labyrinthi­ne, navigation panel. There’s a useful A-Z reference of cmdlets at ss64.com/ps and don’t forget to check Microsoft’s Developer Network at msdn.microsoft.com/ en-us/powershell for lots more resources — go to ‘Documentat­ion > Windows PowerShell’ for a detailed introducti­on.

 ??  ?? Download the latest help files.
Download the latest help files.

Newspapers in English

Newspapers from Australia