Getting data from gridview when checkbox is checke
I have a gridview which contains a checkbox field that I hae binded to my datasource. I added a checkedchanged event to the checkbox field which does fire but I cannot get the code correct to capture any data contained in the row that the checkbox is in.
I tried this:
Protected Sub chbTracking_CheckedChanged(ByVal sender As Object, ByVal e As System.EventArgs)
Dim test As String
test = gvClients.SelectedDataKey.Value.ToString
Label1.Text = test
and have also read numerous online gridview examples but I can figure out had to identify the selected row or cell values that I need.
|