AD Function Template

At the moment I tend to write quite a lot of functions relating to Active Directory. As such I’ve created a small template script I can use for all these functions. In the first part of the template I include comments which can be displayed with the Get-Help Cmdlet.

Continue reading

Testing Objects, Functions, Pipelines

I’ve modified a small test function I’ve seen somewhere else on the web. It shows how a function deals with parameters.

A small example to go with the test-function:

In this way you can allow for multiple input methods and you can differentiate between input types. I wonder … Continue reading