LinkButtons within Repeater control

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have created a repeater with a linkbutton for each databound item.

When I fire off the repeater controls ItemCommand event I execute the
following...

For indx = 0 To rpContacts.Items.Count - 1
Dim btnMyContact As LinkButton =
CType(rpContacts.Items(indx).FindControl("btnContact"), LinkButton)
....

NEXT

This works and I can access all of the properties of the linkbutton

What I need to do is determine which linkbutton was clicked and then fire
off a click event for that button.

any suggestions?

Gary T.
 
The LinkButton can raise a Click event, in which case the sender
parameter is a reference to the LinkButton, you'll just need to
coherce it to the proper type.
 
Back
Top