title: c# - Click on link to create a table?
body: <p>Hmmm not sure how to exactly ask this. </p>
  
  <p>What i want to do is to be able to click on a link called surname and then below i want a table generated with a list of everyone with that surname from the database.</p>
  
  <pre><code>&lt;input type="text" id="surname" name="surname" size="10" /&gt;&lt;a href="javascript:surname();"&gt;Surname&lt;/a&gt; 
          &lt;input type="text" id="forename" name="forename" size="10" /&gt;&lt;a href="javascript:forename();"&gt;Forename&lt;/a&gt; 
  
          &lt;table id = "t" visible="false" runat="server"&gt;
          &lt;tr&gt;
              &lt;th&gt;Surname&lt;/th&gt;
              &lt;th&gt;Forename&lt;/th&gt;
              &lt;th&gt;D.O.B&lt;/th&gt;
          &lt;/tr&gt;
          &lt;/table&gt;
  </code></pre>
  
  <p>To get the data the quesry select * from surname will return surname, forname and d.o.b</p>
  
  <p>This is roughly what i have at the moment. I know i have to call a function somwhere and then return something to generate the data in side the table 't' but how?</p>