I have got a gridview with certain rows/columns and an edit button for each row. When the edit button is clicked, it opens a popup window with a textbox and a button. I want to know the index of the selected row on click of the button inside the popup. I added code like so
var table = document.getElementById('<%= gvTimeSlots.ClientID%>');
var Row;
for (var i = 1; i < table.rows.length; i++) {
Row = table.rows[i];
alert(Row);
}
But the alert gives me "Undefined". What am I missing here?