I have a grid panel with check box selection model.

When retrieving data, i use this code to set the selected rows.

Dim sm As CheckboxSelectionModel = CType(GrdAllowance.GetSelectionModel(), CheckboxSelectionModel)
sm.ClearSelections()
While sqlrd.Read()
If (sqlrd("IsChecked").ToString = "YES") Then
Dim value As String = IIf(IsDBNull(sqlrd("AllowanceID")), "", sqlrd("AllowanceID").ToString().Trim())
sm.SelectedRows.Add(New SelectedRow(value))
End If
End While
sqlrd.Close()

after i check or uncheck others row, and then want to get original selected rows by refreshing the grid(using the same code above),
the selected rows won't be set to original selected rows unless i refreshed the page.
i have attached the screenshots.

Any idea why?
pardon my english.

Click image for larger version. 

Name:	Refresh Selected Rows on Grid Panel with Check box selection model.jpg 
Views:	1 
Size:	82.2 KB 
ID:	25110