Friday, September 21, 2012

Error Type: Microsoft SharePoint is not supported with version 4.0.30319.17626 of the Microsoft .Net Runtime (Powershell).


After installing SharePoint 2010 on Windows Server 2008 R2 am getting the following while executing powershell cmdlet i.e
 
"Microsoft SharePoint is not supported with version 4.0.30319.17626 of the Microsoft .Net Runtime"



Then i checked version of the powershell using cmdlet "$PSVersionTable"

 
 
In order to make use of the powershell cmdlets, need to switch powershell version back to version 2.
 
Note: This will not uninstall version 3, it will launch a new instance that use version 2.
 
Powershell cmdlet to switch powershell version 2 is "powershell -version 2"
 
 
Then run Add-PSSnapin powershell cmdlet
 
 
 
Now powershell switch to version 2, we can run powershell cmdlets ..
 
 
Thats it...



1 comment: