Asp.net with MVC multiple model in one view (create, update)
Posted
by
Abdalmohaymen
on Stack Overflow
See other posts from Stack Overflow
or by Abdalmohaymen
Published on 2011-03-10T23:23:17Z
Indexed on
2011/03/11
0:10 UTC
Read the original article
Hit count: 102
asp.net-mvc
I have problem in asp.ne Mvc with multiple model in one view on create and update I 'm work on exams system class Questions and class Answers Question is aparent class and Answers is a child class
[Bind(exclude("id"))]
class Quesions
{
public string question{get; set;}
public Datetime Timepostquestion{get; set;}
}
[Bind(exclude("id"))]
class Answers
{
public string answer{get; set;}
public Datetime Timepostanswer{get; set;}
public questionId {get; set;}
}
in a view I use two classes how to use classes in insert and update what a way which I have to solve my problem
© Stack Overflow or respective owner