Problem:
The name 'ViewBag' does not exist in the current context
Solution:-
You might be missing the
./Views/Web.config file, because you created the project from an empty ASP.NET application instead of using an ASP.NET MVC template.
Nilesh ShahPosted Apr 13, 2017, 10:36 AM