ASP.net Get row index of dynamically added GridView on click
Posted on 2016-09-21
Hi. I add a GridView to my ASP.net page using the following code. I want to be able to get the rowindex
of the GridView when it is clicked. How do I do this?
Dim oGridView As New GridView
oGridView.ID = "Control" & CStr(oCount)
oGridView.Style("Width") = "100%"
oGridView.Attributes.Add("onkeydown", "return (event.keyCode!=13);")
Dim bImageField As New ImageField()
bImageField.DataImageUrlField = "Text1"
oLoadGrid(oGridView, "Select * From Test2")