C
C#11mo ago
!Rushaan

Error while trying to publish WPF Application

C:\Program Files\dotnet\sdk\5.0.411\Microsoft.Common.CurrentVersion.targets(3162,5): error MSB4216: Could not run the "GenerateResource" task because MSBuild could not create or connect to a task host with runtime "CLR4" 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\dotnet\sdk\5.0.411\MSBuild.exe" exists and can be run. [C:\Users\rusha\source\repos\WeatherApp\WeatherApp\WeatherApp.csproj]
C:\Program Files\dotnet\sdk\5.0.411\Microsoft.Common.CurrentVersion.targets(3184,7): error MSB4028: The "GenerateResource" task's outputs could not be retrieved from the "FilesWritten" parameter. Object does not match target type.
C:\Program Files\dotnet\sdk\5.0.411\Microsoft.Common.CurrentVersion.targets(3162,5): error MSB4216: Could not run the "GenerateResource" task because MSBuild could not create or connect to a task host with runtime "CLR4" 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\dotnet\sdk\5.0.411\MSBuild.exe" exists and can be run. [C:\Users\rusha\source\repos\WeatherApp\WeatherApp\WeatherApp.csproj]
C:\Program Files\dotnet\sdk\5.0.411\Microsoft.Common.CurrentVersion.targets(3184,7): error MSB4028: The "GenerateResource" task's outputs could not be retrieved from the "FilesWritten" parameter. Object does not match target type.
MSBuild.exe was not present in the folder give in error so from somewhere of Visual Studio folder I found MSBuild.exe and copy pasted it in that folder and still getting the exact same error.. The command I ran was dotnet publish -c Release
0 Replies
No replies yetBe the first to reply to this messageJoin
Want results from more Discord servers?
Add your server