Skip to content

Instantly share code, notes, and snippets.

@BartVandyck
Created November 1, 2013 16:41
Show Gist options
  • Save BartVandyck/7268154 to your computer and use it in GitHub Desktop.
Save BartVandyck/7268154 to your computer and use it in GitHub Desktop.
PowerShell snippet to check if the SharePoint module is already loaded. If not load it.
if (-not$(Get-pssnapin Microsoft.SharePoint.PowerShell -erroraction "SilentlyContinue")) {Add-PSSnapin Microsoft.SharePoint.PowerShell}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment