title: Binding custom class property of an ASP.NET control from ASCX markup
body: <p>I have an ASCX that inherits from a <code>WebControl</code> that has a 'CustomConfiguration' property of type <code>CollectionConfigurationItem</code>.  This configuration gets set elsewhere in the code, so by the time it gets to the ASCX it is set up to how I wish to use the data.  At this point I'd like to render out another control using this configuration, like so:</p>
  
  <pre><code>&lt;modules:DataModule runat="server" CustomConfiguration="&lt;%# Model.CategoryListConfiguration %&gt;" /&gt;
  </code></pre>
  
  <p>However, breaking into <code>DataModule</code> always results in 'CustomConfiguration' being null, which is the default value for the property.  I've tried adding a <code>Bindable</code> attribute to the property but to no avail, and when I set an EventHandler for the <code>DataBinding</code> event on the <code>DataModule</code> it doesn't even get called.</p>
  
  <p>How can I set this custom-class-typed property from the markup or, failing that what's the second-best method of getting this to work?  Thanks for any light you can shed!</p>