title: Bind to list of object with known types
body: <p>I have following wrapping classes used as view model property:</p>
  
  <pre><code>public abstract class MultipleFormsModel
  {
      public class FormModel
      {
          public int SelectedValue { get; set; }
          public object Model { get; set; }
      }
      public int FormSelector { get; set; }
      public List&lt;FormModel&gt; Models { get; set; }
  }
  public class MultipleFormsModel&lt;T1, T2&gt; : MultipleFormsModel
  {
      public MultipleFormsModel() {}
      public MultipleFormsModel(int val1, T1 model1, int val2, T2 model2)
      {
          Models.Add(new FormModel() { SelectedValue = val1, Model = model1 });
          Models.Add(new FormModel() { SelectedValue = val2, Model = model2 });
      }
  }
  </code></pre>
  
  <p>Then I have some model, which uses the above mentioned wrapping classes.</p>
  
  <pre><code>public class ViewModel
  {
      //... other properties
      public MultipleFormsModel&lt;SomeModel1, SomeModel2&gt; MultipleModels { get; set; }
  
      public ViewModel()
      {
          MultipleModels = new MultipleFormsModel&lt;SomeModel1, SomeModel2&gt;(0, new SomeModel1(), 1, new SomeModel2());
      }
  }
  </code></pre>
  
  <p>This model is passed to the view and displayed using <code>@Html.EditorForModel()</code> call it is displayed. Of course there are some templates for MultipleFormsModel, and FormModel, which draws just the important parts, but that is not interesting for the topic.
  The problem happens when the form is posted back. The values are not bound into the model <code>ViewModel</code>. (And yes, the name and ids of the inputs in the forms are correct)</p>
  
  <p>My guess is that it is caused, because the default model binder treat the <code>ViewModel.Models[x].Model</code> as type <code>object</code>, which has no property. But as you may see it is created as concrete type (either <code>SomeModel1</code> or <code>SomeModel2</code>).
  I read this <a href="http://msdn.microsoft.com/en-us/magazine/hh781022.aspx" rel="nofollow">paper</a> and I suspect the cause is hidden somewhere in the following text:</p>
  
  <blockquote>
    <p>Next, the AbstractModelBinder uses the concrete type name to generate a new set of metadata that describes the details of the concrete class. AbstractModelBinder uses this new metadata to replace the existing ModelMetadata property that described the initial abstract model type, effectively causing the model binder to forget that it was ever bound to a non-concrete type to begin with.</p>
  </blockquote>
  
  <p>The problem here is, that I have no idea where to start. What I need is to make DefaultModelBinder treat the properties types as theirs <strong>real</strong>, not declared types - is it even possible?</p>