9
Answers

the name "model" doesnt exist in the current context error

Rakesh

Rakesh

8y
2k
1

I upgrade my solution from 2013 to 2015 and v4.6 framework. I have only two projects in solution. when I  build my solution , it seems to build successfully but when I look at the error list, I am seeing erros on

@model and Html helpers.. etc.

It says The name "model" does not exist in the current context

The name "ViewBag" does not exist in the current context .
 
 
 
My application is MVC 4 version. Please help! 
 
 
Answers (9)
0
  • The C# language is intended to be a simple, modern, general-purpose, object-oriented programming language.
  • The language, and implementations thereof, should provide support for software engineering principles such as strong type checking, array bounds checking, detection of attempts to use uninitialized variables, and automatic garbage collection. Software robustness, durability, and programmer productivity are important.
  • The language is intended for use in developing software components suitable for deployment in distributed environments.
  • Source code portability is very important, as is programmer portability, especially for those programmers already familiar with C and C++.
  • Support for internationalization is very important.
  • C# is intended to be suitable for writing applications for both hosted and embedded systems, ranging from the very large that use sophisticated operating systems, down to the very small having dedicated functions.
  • Although C# applications are intended to be economical with regard to memory and processing power requirements, the language was not intended to compete directly on performance and size with C or assembly language.