Visual Studio – “Could not run the GenerateResource” after conversion

Problem:
After a project upgrade/update/convert you receive the following error on Build:

Could not run the “GenerateResource” task because MSBuild could not create or connect to a task host with runtime “CLR2? and architecture “x86?. Please ensure that (1) the requested runtime and/or architecture are available on the machine, and (2) that the required executable “C:\Program Files (x86)\MSBuild\12.0\bin\MSBuildTaskHost.exe” exists and can be run.

Solution:
Edit your project file (.csproj | .vbproj) with a text editor such as Notepad.
Manually add this line at the end of the first PropertyGroup node:

<PropertyGroup>

<DisableOutOfProcTaskHost>true</DisableOutOfProcTaskHost>
</PropertyGroup>

1 thought on “Visual Studio – “Could not run the GenerateResource” after conversion

Leave a Reply

Your email address will not be published. Required fields are marked *