I feel guilty asking a question like this around here, but I\'m at a loss and would appreciate some help.
A proof-of-concept like web application was built on one PC
Right Click on Solution. Go to Manage Nuget Packages for this Solution. Search forMicrosoft.Net.Compilers on Browse Section.
For me I was trying to open a MVC5 project in VS 2013 and I was getting this error, Opened it in VS 2017 and up it worked just fine.
I got this error when I created a new branch for my project.
It drove me crazy for an hour. I tried most of the suggestions over the internet including the accepted answer to this question.
I then closed the project, opened it again, cleaned it and the error is gone. So this means this could be cache issue.
Anyways, just wanted to share.
Microsoft.Net.Compilers
.Deleting these three directories solves the problem.
NOTE: delete both /bin and /obj from all projects included in the solution (including Test projects).
In my case, the solution was:
Microsoft.CodeDom.Providers.DotNetCompilerPlatform
.