title: how to set the value of a variable in repeater
body: <p>i want call a function in aspx page in the repeater:</p>
  
  <pre><code> &lt;asp:Repeater ID="Rpt_M" runat="server"&gt;
      &lt;HeaderTemplate&gt;&lt;/HeaderTemplate&gt;
      &lt;ItemTemplate&gt;
      &lt;a href="noktaDetay.aspx?id=1" &gt;&lt;%# Container.DataItem(1)%&gt;&lt;/a&gt;
      &lt;%Dim yorumid As Integer = Eval("DnAd")
        Dim yorumadet = yorumsay(yorumid)
        Dim yorumyaz As String = yorumadet + " adet yorum var"
        If yorumadet = 0 Then yorumyaz = "bla bla bla"%&gt;
      &lt;a href="yorumlar.aspx?id=1"&gt;&lt;%=yorumyaz%&gt;&lt;/a&gt;
      &lt;/ItemTemplate&gt;
      &lt;FooterTemplate&gt;&lt;/FooterTemplate&gt;
      &lt;/asp:Repeater&gt; 
  </code></pre>
  
  <p>When I run the code I get this error:</p>
  
  <p>Databinding methods such as Eval(), XPath(), and Bind() can only be used in the context of a databound control.</p>
  
  <p>How can I set the value for yorumid instead of using eval("DnAd")?
  Thank you for any help.</p>