ok I am fascinated here... I am dynamically adding two different linkbuttons into a GridView cell at runtime (RowDatabound event)
button 1)"Accept"
button 2)"Deny"
-----
Once rendered, the "Accept" button fires the Rowcommand event but the "Deny" button does not.
I even swapped: CommandName, ID, and Text properties between them. No matter what I do it is always the 1) button that fires and never the 2) button
WHY? .... any ideas?
button 1)"Accept"
button 2)"Deny"
-----
Once rendered, the "Accept" button fires the Rowcommand event but the "Deny" button does not.
I even swapped: CommandName, ID, and Text properties between them. No matter what I do it is always the 1) button that fires and never the 2) button
WHY? .... any ideas?
Code:
Dim CancelButton As New LinkButton Dim DenyButton As New LinkButton DenyButton.ID = "Deny" DenyButton.Text = "Deny" DenyButton.CommandName = "Deny" DenyButton.ForeColor = Drawing.Color.DarkGray AcceptButton.ID = "Accept" AcceptButton.Text = "Accept" AcceptButton.CommandName = "Accept" AcceptButton.ForeColor = Drawing.Color.DarkGreen e.Row.Cells(CellNum).Controls.Add(AcceptButton) e.Row.Cells(CellNum).Controls.Add(DenyButton)
Comment