title: How do I make my ASP.NET server control take an embedded code block as a property value?
body: <p>I have a custom server control with a property of Title.  When using the control, I'd like to set the value of the title in the aspx page like so:</p>
  
  <pre><code>&lt;cc1:customControl runat="server" Title='&lt;%= PagePropertyValue%&gt;' &gt;
  more content
  &lt;/cc1:customControl&gt;
  </code></pre>
  
  <p>When I do this, however, I am getting the exact String &lt;%= PagePropertyValue%> being displayed rather than the Property Value that I would like to see.</p>
  
  <p>So after trying the databinding expression (as suggested below).  I don't get the string literal that looked bad but I don't get anything else either.  </p>
  
  <pre><code>&lt;cc1:customControl runat="server" Title='&lt;%# PagePropertyValue%&gt;' &gt;
  more content
  &lt;/cc1:customControl&gt;
  </code></pre>
  
  <p>What do I need to do to my custom control to take this sort of value? Or is there something I need to do to the page.</p>