Description

A simple Powershell script to quickly implement the fix indicated in http://support.microsoft.com/kb/2481844 (SharePoint 2010: Error 7043 "Load control template file /_controltemplates/TaxonomyPicker.ascx failed")

Note, the MS fix above seems itself to have a bug, namely a missing semi-colon (;) after the string of characters to replace. I've updated the script below to include the ; after &#44

Script

PowerShell
Edit|Remove
# Powershell script to implement the fix suggested in http://support.microsoft.com/kb/2481844 
 
$TaxonomyPickerControl = "$env:CommonProgramFiles\Microsoft Shared\Web Server Extensions\14\TEMPLATE\CONTROLTEMPLATES\TaxonomyPicker.ascx" 
Write-Host " - Making a backup copy of TaxonomyPicker.ascx..." 
Copy-Item $TaxonomyPickerControl $TaxonomyPickerControl".bad" 
$NewTaxonomyPickerControl = (Get-Content $TaxonomyPickerControl-replace ','"," 
Write-Host " - Writing out new TaxonomyPicker.ascx..." 
Set-Content -Path $TaxonomyPickerControl -Value $NewTaxonomyPickerControl 
Write-Host " - Done! Press any key to exit..." 
$null = $host.UI.RawUI.ReadKey("NoEcho,IncludeKeyDown")