I was recently working with an empty ASP.NET MVC 4 Web Application project and I encountered the following error message:
"The name Scripts does not exist in the current context"
I figured this had to do with the missing System.Web.Optimization DLL, therefore, I went into NuGet and installed the Microsoft ASP.NET Web Optimization Framework.:
However, after installing this from NuGet, I noticed that I was STILL receiving this error message in Visual Studio!
After doing some more research, I found numerous articles stating that I needed to manually add the System.Web.Optimization namespace to BOTH the Web.config at the root level as well as in the Views directory.
After doing that, I STILL could not get rid of this error message in Visual Studio 2013!!!
So, as a last resort, I decided to close the solution and re-open it in Visual Studio. Sure enough, that did the trick!!
"The name Scripts does not exist in the current context"
I figured this had to do with the missing System.Web.Optimization DLL, therefore, I went into NuGet and installed the Microsoft ASP.NET Web Optimization Framework.:
However, after installing this from NuGet, I noticed that I was STILL receiving this error message in Visual Studio!
After doing some more research, I found numerous articles stating that I needed to manually add the System.Web.Optimization namespace to BOTH the Web.config at the root level as well as in the Views directory.
After doing that, I STILL could not get rid of this error message in Visual Studio 2013!!!
So, as a last resort, I decided to close the solution and re-open it in Visual Studio. Sure enough, that did the trick!!
No comments:
Post a Comment