PowerShell Basics: ElseIf Statement

Introduction to PowerShell’s Else If Logic PowerShell’s ‘ElseIf’ statement comes under the umbrella of flow control. Once you master the basic ‘If’ construction then you can increase the scope of your script by adding extra ‘ElseIf’ statements to the logic control. Topics for PowerShell’s ElseIf Statement Begin With The Plain …

PowerShell 3.0 $PSDefaultParameterValues New in PowerShell 3.0 is the ability to control the default value of parameters such as Logname. This technique, using a built-in variable called $PSDefaultParameterValues will save you typing if you spend a lot of time with a cmdlets such as Get-Eventlog. PowerShell Default Parameter Topics Refresher: …
New Aliases in PowerShell v3 Version 3 introduces eleven new shortcuts for regular PowerShell cmdlets, for example 'sls' for Select-String. However, the most interesting part of this page is the journey towards identifying those extra aliases in the latest PowerShell version. PowerShell New Alias Topics Get-Alias: Count List Each Alias’s …
How to Filter the WMI Classes My aim is to provide an easy way to search for a class amongst the 800+ WMI (Windows management instrumentation) objects. I will provide instructions for creating a Windows PowerShell function; in particular I want to highlight creating parameters. Guy's Get-WMIClass Function (Cmdlet) Planning …
Manipulate the Browse Master with PowerShell Our mission is to control the Computer Browser Service, we will do this by changing a registry value called MaintainServerList. The benefit is to control which machine on the network keeps a map of all the computers on the network. Our main method uses …