After installing the ASP.NET and Web Tools 2015 (RC1 update 1) I get the following error within ASP.NET MVC 4 projects when opening *.cshtml
files:
Delete bin and obj folders in all projects of that solution.
Seems like those folders were having old files generated by some older version of visual studio, which are not compatible with new version of visual studio.
Delete %LocalAppData%\Microsoft\VisualStudio\14.0\ComponentModelCache
and restart Visual Studio.
Alternatively, use the Clear MEF Component Cache extension.
The solution to the issue when i had this earlier today was that there was an additional set of tags bolted on the end of my Web.config. Once removed the functionality returned.
For me,
VsHub.exe
.After that, everything works like a charm again!
I was getting an exception every time I tried to create a "new" project.
My solution was:
Go menu Tools → Extensions and Updates
Check the "Updates" link... There was an update to Microsoft ASP.NET and Web Tools. Install it.
That fixed it for me.
After trying the top answer, I found that you must also restart the computer. The error may be part of a git issue as well where restarting your computer will reset.