Suppose the gridview contains four columns with the last two column as template with Hyperlink
When I click that Hyperlink I need that value in some where say TextBox

and in the code behind GridView1_RowCommand event
If e.CommandName = "claim" Then
Dim index As Integer = Convert.ToInt32(e.CommandArgument)
Dim row = GridView1.Rows(index)
Dim lin As LinkButton = CType(row.FindControl("ClaimLink"), LinkButton)
Dim lin2 As LinkButton = CType(row.FindControl("TransLink"), LinkButton)
ClaimID.Text = lin.Text
TRansID.Text = lin2.Text
End If
When I click that Hyperlink I need that value in some where say TextBox
and in the code behind GridView1_RowCommand event
If e.CommandName = "claim" Then
Dim index As Integer = Convert.ToInt32(e.CommandArgument)
Dim row = GridView1.Rows(index)
Dim lin As LinkButton = CType(row.FindControl("ClaimLink"), LinkButton)
Dim lin2 As LinkButton = CType(row.FindControl("TransLink"), LinkButton)
ClaimID.Text = lin.Text
TRansID.Text = lin2.Text
End If
No comments:
Post a Comment