0

My other razor view pages have @ViewBag.Something, and those are not creating any problem.

But I have added a layout page in the shared directory, which contains @ViewBag.Something.

Now I am getting -

'viewbag' does not exist in the current context

What did I miss in my project?

s.k.paul
  • 7,099
  • 28
  • 93
  • 168
  • How are you using it ? Are you getting a IDE warning or run time error? – Shyju Nov 26 '17 at 14:18
  • Have you tried any of this?https://stackoverflow.com/questions/4960148/the-name-viewbag-does-not-exist-in-the-current-context – Eduard Nov 26 '17 at 14:28

0 Answers0