dynamic value in textbox
<p>I have a text box like this:</p>

<pre><code>&lt;asp:TextBox ID="txtLogin" runat="server" Text='&lt;%# strUserID %&gt;'&gt;&lt;/asp:TextBox&gt;
</code></pre>

<p><code>strUserID</code> is a string value set in my codebehind and I bind the textbox to see the value. I tried with <code>&lt;%= strUserID %&gt;</code>, but it doesnt work for me. can you please tell me why?</p>

<p>Also, I have a hidden field like this:</p>

<pre><code>&lt;input id="hdnUserID" runat="server" type="hidden" value='&lt;%=txtLogin.ClientID %&gt;'  /&gt;
</code></pre>

<p>and I have a function prints the hidden field value like this:</p>

<pre><code>function CheckForValue()
{
    var uid = window.document.getElementById('&lt;%= txtLogin.ClientID %&gt;').value;
    alert(hdnUserID);

    return false;
}
</code></pre>

<p>But this alert always prints as "[object]". Can anyone please explain this? Looks like <code>&lt;%= value %&gt;</code> doesnt work at all. But I have seen in my earlier projects where the existing code has these kinda lines!!</p>
