title: ASP.NET Listview hiddenfield value is empty onselect
body: <p>i searched a lot of question, read a lot of solutions but still haven't found the one which solve the problem i'm struggling with:
  my listview shows a few pictures from a directory, but sometimes i forgot to rotate a picture, there i want a button to select a item and then a button to rotate the picture shown. but i can't resolve the value in the 2 hiddenfields which hold the URL values. i get the start value and not the evaluated value: </p>
  
  <pre><code>Dim URLorg As HiddenField = TryCast(FotoListView.Items(FotoListView.SelectedIndex).FindControl("URLorigineel"), HiddenField)
  </code></pre>
  
  <p><strong>URLorg.value gives >>  "../&lt;%# Eval("URLorigineel") %>"</strong></p>
  
  <p>Source:</p>
  
  <pre><code>&lt;asp:ListView runat="server" ID="FotoListView"    ItemPlaceholderID="PlaceHolder3"     DataSourceId='odsAvailableFotos' DataKeyNames="ID"&gt;
      &lt;LayoutTemplate&gt;
          &lt;ul&gt;
              &lt;div style="overflow:scroll; height:380px;"&gt;                                             &lt;asp:PlaceHolder runat="server" ID="PlaceHolder3" /&gt; 
              &lt;/div&gt; 
          &lt;/ul&gt;
      &lt;/LayoutTemplate&gt;
      &lt;ItemTemplate&gt;
          &lt;li&gt;
              &lt;hr /&gt;
              &lt;asp:LinkButton runat="server" ID="LinkButton1" Text="Select" CommandName="Select" BackColor="#33CCFF" BorderColor="#003399" Width="70"  CssClass="PhotoEditBtn" Height="15" /&gt;  
              &lt;a href='../&lt;%# Eval("URLorigineel") %&gt;' target="_blank" id="ImageRef"&gt;&lt;%# Eval("Caption")%&gt;&lt;br /&gt;
                  &lt;img src='../&lt;%# Eval("URL") %&gt;' alt="Click to see image"  class="Rounded_image_sample" id="ImgSource" /&gt;
              &lt;/a&gt; 
              &lt;asp:HiddenField ID="URL" runat="server" Value='../&lt;%# Eval("URL") %&gt;' /&gt;
              &lt;asp:HiddenField ID="URLorigineel" runat="server" Value='../&lt;%# Eval("URLorigineel") %&gt;' /&gt;
          &lt;/li&gt;
      &lt;/ItemTemplate&gt;
      &lt;SelectedItemTemplate&gt;
          &lt;li&gt;
              &lt;hr /&gt;
              &lt;asp:LinkButton runat="server" ID="LinkButton1" Text="Delete" CommandName="Delete" BackColor="#33CCFF" BorderColor="#003399" Width="70"  CssClass="PhotoEditBtn" Height="15" /&gt;  
              &lt;asp:Label ID="dummy1" runat="server" text="     " /&gt;
              &lt;asp:LinkButton runat="server" ID="LinkButton2" Text="Rotate" CommandName="Rotate" CssClass="PhotoEditBtn" BackColor="#33CC33" Width="70" Height="15" /&gt; 
              &lt;asp:LinkButton runat="server" ID="LinkButton3" Text="Cancel" CommandName="ANnuleer" CssClass="PhotoEditBtn" BackColor="#33CC33" Width="70" Height="15" /&gt;
              &lt;br /&gt;
              &lt;a href='../&lt;%# Eval("URLorigineel") %&gt;' target="_blank" id="ImageRef"&gt;&lt;%# Eval("Caption")%&gt;&lt;br /&gt;
                  &lt;img src='../&lt;%# Eval("URL") %&gt;' alt="Click to see image"  class="Rounded_image_sample" id="ImgSource" /&gt;
              &lt;/a&gt; 
              &lt;asp:HiddenField ID="URL" runat="server"  Value='../&lt;%# Eval("URL") %&gt;' /&gt;
              &lt;asp:HiddenField ID="URLorigineel" runat="server" Value='../&lt;%# Eval("URLorigineel") %&gt;' /&gt;
          &lt;/li&gt;
      &lt;/SelectedItemTemplate&gt;
  
  &lt;/asp:ListView&gt;
  </code></pre>