To explain my problem, an example is better.
I have an ASP.NET MVC 3 controller action who return a view with an object as a Model.
This object, contains some business properties used by the view like a list of contacts, for example.
If i call a property of my object in the view (from Model.) and, after that, I change this property name, the debugger of visual studio say nothing.
However, this one should alert me that I try to load, in the view, a property who doesn’t exist !
Moreover, when i compile this project, it passes until i try to render the view !
Is there a way to check that from visual studio ?
Thank’s by advance !
You could enable compilation of your ASP.NET MVC views by putting the following in your
.csproj:This way you will get a compile-time error.