title: MVC model not binding on post
body: <p>Can't figure out what I'm doing wrong. When the form in the view is posted the model properties turn out to be null.</p>
  
  <h2>Model</h2>
  
  <pre><code>public class RegistrationModel
  {
      public RegistrationModel()
      {
          Registration = new REGISTRATION();
          AddPayment = true;
      }
      public REGISTRATION Registration { get; set; }
      public bool AddPayment { get; set; }
  }
  </code></pre>
  
  <h2>View</h2>
  
  <pre><code>@model Client.Models.RegistrationModel
  
  @using (Html.BeginForm())
  {
      @Html.AntiForgeryToken()
      @Html.ValidationSummary(excludePropertyErrors: false)
  
      &lt;div class="form-group"&gt;
          @Html.DropDownList("SECTION_ID", null, string.Empty, new { @class = "form-control" })
      &lt;/div&gt;
  
      &lt;div class="form-group"&gt;
          @Html.DropDownList("STUDENT_ID", null, string.Empty, new { @class = "form-control" })
      &lt;/div&gt;
  
      &lt;div class="form-group"&gt;
          @Html.DropDownList("STATUS_ID", null, string.Empty, new { @class = "form-control" })
      &lt;/div&gt;
  
      &lt;div class="form-group"&gt;
          @Html.CheckBoxFor(model =&gt; model.AddPayment)
      &lt;/div&gt;
  
      &lt;p&gt;
          &lt;input type="submit" class="btn btn-success" value="Create" /&gt;
      &lt;/p&gt;
  }
  </code></pre>
  
  <h2>Controller</h2>
  
  <pre><code>    public ActionResult Create()
      {
          //code to populate view dropdowns
          return View();
      }
  
  
      [HttpPost]
      [ValidateAntiForgeryToken]
      public ActionResult Create(RegistrationModel model)
      {
          WriteFileLog(_logPath, Newtonsoft.Json.JsonConvert.SerializeObject(model));
      }
  </code></pre>
  
  <p>In the controller's Create action that handles the post model properties are null.</p>
  
  <p>Registration Class (autogenerated by EF from database):</p>
  
  <pre><code>public partial class REGISTRATION
  {
      public REGISTRATION()
      {
          this.REGISTRATION_AUDIT = new HashSet&lt;REGISTRATION_AUDIT&gt;();
      }
  
      public int ID { get; set; }
      public int SECTION_ID { get; set; }
      public int STUDENT_ID { get; set; }
      public int STATUS_ID { get; set; }
  
      public virtual ICollection&lt;REGISTRATION_AUDIT&gt; REGISTRATION_AUDIT { get; set; }
      public virtual SECTION SECTION { get; set; }
      public virtual V_REGISTRATION_STATUS V_REGISTRATION_STATUS { get; set; }
      public virtual PERSON PERSON { get; set; }
  }
  </code></pre>