0
Posted on 12:43 AM by Softminer and filed under

Usually by default the Views in MVC are Inherited from Inherits="System.Web.Mvc.ViewPage but you can Inherit it from specific Model.


first you have to define your model in your MVC Model folder. but when I add this to Page


Inherits="System.Web.Mvc.ViewPage<MyProject.Models.MyModel>"  then I get the following Error :



Compiler Error Message: CS0426: The type name 'Models' does not exist in the type 'System.Web.UI.WebControls.Wizard'


Solution:


<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/Site.Master" Inherits="System.Web.Mvc.ViewPage<MyModel>" %>


<%@ Import Namespace="MyProject.Models" %>
0
Responses to ... MVC Models Problem