I'm working on a project with .NET and MVC and I can't build my solution for each project I get this error:
C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Roslyn\Microsoft.CSharp.Core.targets(84.5): Error MSB6006: "csc.exe" exited with code -532462766.
I was working on this project in VS 2015 and they changed my machine (PC), I installed the VS 2017 Community and it started throwing that error. Tried various things like delete bin
and obj
, run as administrator, etc and nothing worked.
You need to install the nuget package
Microsoft.Net.Compilers
in your project.If it doesn't come out, check the creation date of your project in reference to the package, for example, if you installed it before 5/17/2016, this version corresponds to you:
Package reference: https://www.nuget.org/packages/Microsoft.Net.Compilers/