I have started a new console project in VS2015. I only have this code :
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text
I had visual studio 2015 with an ASP.net MVC5 arcitectured with DDD (Domain Driven Design). The problem was the same since I just opened visual studio normally.
The problem was solved when I closed all instance visual studio and restarted as an adminstrator.
There is no need to delete everything in my case, I just opened the
"CurrentSettings.vssettings"
file and commented this property
<PropertyValue name="DefaultBehaviorForStartupProjects">1</PropertyValue>
and everything fixed.
Sample
I just had the same problem and solved it by deleting the .vs directory in the project directory.
Make sure you're launching Visual Studio as Administrator.
This has resolved the issue for me with the exact error message in question.
It is not ideal to run the VS in administrator mode at all times. Make sure you un-check the box once your issue has been resolved.
I had this problem when I tried to start (without) Debugging
my Asp.Net MVC project
are you running Visual studio as Administrator
so just
restart
visual studio AsAdministrator
I had this with a Xamarin.iOS project in my Xamarin.Forms solution. I tried every suggestion here, without success.
The source of the error was a misconfigured .csproj of the project. I never edited it myself and not even touched the project properties. I use Visual Studio 2017 RC. I came across the solution when I compared the project file with previous versions on Source Control.
Solution: Compare the project file with a previous version and try to granually revert changes until you eliminated the problem and know what the cause was.