November 13, 2013

Power Shell script execution issue

​If you are getting this type of error "File C:\Projects\test.ps1 cannot be loaded because the execution of scripts is disabled on this system" then resolved it by following steps:-

Determine power cell script is enabled or not run below command
    get-executionpolicy
Enabled power cell script run below command
    set-executionpolicy unrestricted

To execute the Set-ExecutionPolicy command, you must have administrator permission and for Windows Vista / Windows Server 2008 and later versions you have to open the PowerShell command prompt with Run as Administrator. Otherwise you will get the below error



If you have any questions you can reach out our SharePoint Consulting team here.

No comments:

Post a Comment