< asp : GridView ID =" grdTest " runat = " server " AutoGenerateColumns = " False " ClientIDMode = " AutoID "
DataKeyNames = " ID ">
< / asp : GridView >
Jeigu GridView nurodome ClientIDMode, tai dar nereiškia, kad kiekvienai eilutei bus sugeneruotas unikalus ID. Jis generuojamas tik tada, jei RowDataBound įvykyje kviečiame e.Row.ClientID.
Protected Sub grdTest_RowDataBound(ByVal sender As Object, ByVal e As System.Web.UI.WebControls.GridViewRowEventArgs) Handles grdTest.RowDataBound
If e.Row.RowType = DataControlRowType.Header Then
hlDuplicate.NavigateUrl = "javascript:duplRow(" & oRW("ID") & ",'" & e.Row.ClientID & "')"
End If
End If
Komentarų nėra:
Rašyti komentarą