Changing input value using javascript
<p>I've been looking for a reason why this doesn't work, but I can't find one.  In my asp.net application I create a a bunch of hidden inputs in c# and then try to modify them in javascript before I call them back to the server.</p>

<p>My c# code:</p>

<pre><code>    hidden3 = new HtmlInputHidden();
    hidden3.ID = "total";
    hidden3.Value = index.ToString();
    this.Controls.Add(hidden3);
</code></pre>

<p>my javascript code:</p>

<pre><code>     mod = document.getElementById("total");
     mod.value = newVal;
</code></pre>

<p>I can call the value back fine but it doesn't change.  I have also added alerts for the original value and then the value after changing values and they both show up fine.  However the code is never changed so when I pull the values </p>

<p>To get the value back I am using this;</p>

<pre><code>    HtmlInputHidden hiddenControl = (HtmlInputHidden)FindControl("total");
</code></pre>
