title: asp.net databind gridview with vertical scrollbar
body: <p>i have some long data in my gridview and need a scrollbar (to the gridview). 
  try few ways - non of them works.
  i guess because the postback or the databind..</p>
  
  <p>the asp.net code:</p>
  
  <pre><code>&lt;asp:GridView ID="gvGuess" runat="server" AllowSorting="True" OnSorting="gridView_Sorting" OnRowCreated="GridView1_RowCreated" OnRowDataBound="gvGuess_RowDataBound" Style="top: 301px; left: 212px; direction: rtl; overflow:scroll; position: absolute; height: 176px; width: 359px" BackColor="White" BorderColor="#E7E7FF" BorderStyle="None" BorderWidth="1px" CellPadding="3" GridLines="None"&gt;
  
   &lt;AlternatingRowStyle BackColor="#F7F7F7" /&gt;
   &lt;FooterStyle BackColor="#B5C7DE" ForeColor="#4A3C8C" /&gt;
   &lt;HeaderStyle BackColor="#4A3C8C" HorizontalAlign="Center" Font-Bold="True" ForeColor="#F7F7F7" /&gt;
  &lt;PagerStyle BackColor="#E7E7FF" ForeColor="#4A3C8C" HorizontalAlign="Right" /&gt;
  &lt;RowStyle BackColor="#E7E7FF" HorizontalAlign="Center" ForeColor="#4A3C8C" /&gt;
              &lt;SelectedRowStyle BackColor="White" Font-Bold="True" ForeColor="#F7F7F7" /&gt;
              &lt;SortedAscendingCellStyle BackColor="#F4F4FD" /&gt;
              &lt;SortedAscendingHeaderStyle BackColor="#5A4C9D" /&gt;
              &lt;SortedDescendingCellStyle BackColor="#D8D8F0" /&gt;
             &lt;SortedDescendingHeaderStyle BackColor="#3E3277" /&gt;
          &lt;/asp:GridView&gt;
  </code></pre>
  
  <p>and the c# code:</p>
  
  <pre><code>    protected void loadGuess()
      {
    noInfo.Visible = false;
    ds = dataFunk.getGuestsgrid(Convert.ToString(Session["orderNum"]),    Convert.ToString(Session["choice"]));
          gvGuess.AutoGenerateColumns = true;
          gvGuess.DataSource = ds;
          gvGuess.DataMember = dataFunk.getGuestsgrid(Convert.ToString(Session["orderNum"]), Convert.ToString(Session["choice"])).Tables[0].ToString();
              gvGuess.DataBind();}
  </code></pre>
  
  <p>thanks :)</p>