Check First 30 checkbox inside Gridview
I want to check the first 30 checkbox in the gridview with paging enabled on it.

If I use this code, it checks all the checkboxes


    Sub CheckFirst30()
    
    Dim cb As CheckBox
    
    For Each gvr As GridViewRow In grdData.Rows
    
    cb = CType(gvr.FindControl("cbSelect"), CheckBox)
    
    
    cb.Checked = True
    
    Next
    
    End Sub

How can I do it? thanks


Check First 30 checkbox inside Gridview
===

I want to check the first 30 checkbox in the gridview with paging enabled on it.

If I use this code, it checks all the checkboxes


    Sub CheckFirst30()
    
    Dim cb As CheckBox
    
    For Each gvr As GridViewRow In grdData.Rows
    
    cb = CType(gvr.FindControl("cbSelect"), CheckBox)
    
    
    cb.Checked = True
    
    Next
    
    End Sub

How can I do it? thanks

