title: How to find total number of records/rows in gridview?
body: <p>I want to find total number of rows in the gridview. here is my code, page size= 10</p>
  
  <pre><code>   Private Sub GridView_RowDataBound(ByVal sender As Object, ByVal e As System.Web.UI.WebControls.GridViewRowEventArgs) Handles CustomGridView1.RowDataBound
      Dim Count As Integer = CustomGridView1.Rows.Count()
      If e.Row.RowType = DataControlRowType.Footer Then
          e.Row.Cells(5).Text = Count &amp; " of " &amp; getstudents.Count()
      End If
  End Sub
  </code></pre>
  
  <p>Footer shows as, 10 0f 50 in the first page but I want to show as 1-10 of 50 . In the second page it shows the same but I want to show as 11-20 of 50. Can anyone tell me how to show footer text like this.</p>