After installing a very large set of updates at the end of last year (2012) my ability to interact with my SharePoint 2010 installation via the PowerShell ISE failed. Specifically anytime I used scripts that had worked previously as well as a simple Get-SPSite, I was told:
Get-SPSite: Microsoft SharePoint is not supported with version 4.0.30319.296 of the Microsoft .Net Runtime.
After trying a few things like changing the PowerShell_ise.exe.config file to handle the v2 framework, I started searching and came across the solution:
Basically, the solution is to uninstall the “Windows Management Framework 3.0:” which is installed via “KB2506146 – for Windows Server 2008 SP2”.
After a quick reboot, everything is back to normal.
Personally, I think updates pushed out via Microsoft Update should be self aware, perhaps at a greater level so if a machine has SharePoint 2010 installed, then that update can not be installed. Had this happened in a production environment, then yuck…