Hi,
I watched Phil Haacks PDC event - http://mschnlnine.vo.llnwd.net/d1/pdc08/WMV-HQ/PC21.wmv In this, he is using entity framework.
I have started to play with ASP.NET MVC, trying to create the same using LLBLGen instead of using Entity Framework or Linq.
When a View contains the fields with same names as fields od the entity, on postback the function magically gets the entity object with all the fields filled in.
View Code
<% using (Html.BeginForm()) { %>
<%= Html.TextBox("Question.Title")%>
<br />
<%= Html.TextBox("Question.Body")%>
<br />
<input type="submit" value="Submit" />
<% } %>
Controller Code
[AcceptVerbs(HttpVerbs.Post)]
public ActionResult Ask(QuestionEntity question)
{
return View();
}
This magic as I understand is done using reflection. But in case of LLBLGen is am getting the question paramater as null.
Any ideas???
Thanks!