PowerShell Arrays and that annoying number on the screen
When you create an array and populate it in PowerShell the number of elements is written out to the screen, very annoying. e.g. Output So how do we stop the numbers from being displayed to the screen, while Fix 2 is the proper way I like fix 1 as it reminds me of passing things […]
Keeping your PowerShell tidy
I am quite a fan of Powershell but miss the ability to include other files in a simple and clean way. I quite like the idea that as you run scripts in the different environments dev, test, UAT, staging and production they should never change, the only thing that should change are the variables in […]
PowerShell script to create an AD group in an OU
Active directory you have got to love it, using it as a base to secure up access to SharePoint is quite an important thing to understand but who wants to create the groups, better pass it over to a script to do. This script is a starter and will create an AD group in a […]
What site template did that SharePoint site start as?
Sometimes you need to figure out what template was used when creating a SharePoint site, you can mess about in the database (not recommended) you can look in the HTML of an output page as long as your master page has not changed some of the default options or you can open up the SharePoint […]
Move that SharePoint SubSite into its own site collection.
So it seemed like a good idea at the time, all of the sites on the root site collection but now you are beginning to regret that the content database is getting a little on the large side and managing the security is getting to be a pain. So how do you move this subsite […]
Finding that SharePoint Correlation ID
So you have an issue in SharePoint and a screenshot form a user in a production environment. You have asked the production support team to put SharePoint log viewer onto the server and they have submitted the request to the change group and will get back to you in a couple of days and in […]
PowerShell script template
This file is the Powershell template file that I use when creating PowerShell scripts. The code below is a functioning PowerShell script for you to build on, it has the syntax for the Get-Help cmdlet to function correctly and takes three parameters some mandatory some not, it also outputs to the screen the script execution […]