title: How to pass variable from hidden input box to another page
body: <p>I am trying to get a value from a hidden input text box to another page, but it doesn't work. How to pass variable from hidden input box to another page?</p>
  
  <pre><code>Page1.asp
  &lt;input type="hidden" name="FormID" value="&lt;% objRS("Form_id")%&gt;
  ...
  &lt;input type="hidden" name="FormID" value="&lt;%= nFormID %&gt;"&gt;
  &lt;input type="button" value="Open Page2" onclick=openwin();"/&gt;
  
  Page2.asp
  &lt;% 
  iFormID = Request.Form("FormID")
  sSQL = "select * from Form where Form_id = " &amp; iFormID
  </code></pre>
  
  <p>When I click on the Button Open Page2, it doesn't get the value of FormID.
  How do I fix it to get the FormID from Page1.asp?</p>
  
  <p>Updated: when I tried to add a button with this JS, it won't get the variable from Page1.asp
  I added this on page1.asp:</p>
  
  <pre><code>function openwin()
  {window.open("Page2.asp","mywindow","width=500,height=400"):}
  &lt;input type="hidden" name="FormID" value="&lt;%= nFormID %&gt;"&gt;
  &lt;input type="button" value="Open Page2" onclick=openwin();"/&gt;
  </code></pre>
  
  <p>Thanks.</p>