I have an ASP.NET MVC 5 web application. In every .cshtml view file i get the following error for Viewbag: One or more types required to compile a dynamic expre
This happened to me after I made a code change on the cshtml page with a syntax error. After correcting the syntax error, the errors persisted. So, I closed the cshtml and re-compiled... success. I reopened the cshtml and the errors were no longer there.