<ajax:UpdatePanel ID="wrapperUpdatePanel" runat="server" UpdateMode="Always">
<asp:Repeater ID="endpointRepeater" runat="server" OnItemDataBound="EndpointDataBound">
<asp:LinkButton ID="endpointLink" runat="server" OnClick="EndpointSelected" />
protected void Page_Load(object sender, EventArgs e)
this.SelectedEndpoint = Factory.Get<IEndpoint>(Enums.EndPoints.Marketing);
IEndpointCollection col = EndpointCollection.GetActivelySubscribingEndpointsForPart(this.Item);
if (col.Count > 0)
this.endpointRepeater.DataSource = col;
if (this.endpointRepeater.Items.Count > 0)
LinkButton lb = this.endpointRepeater.Items.FindControl("endpointLink") as LinkButton;
this.EndpointSelected(lb, new EventArgs());
This may not be your main issue, but when including an object inside a Repeater that needs an event, you shouldn't be using that control's native events. Instead you should use the Repeater's
If I were to guess, your problem is caused by the repeater not maintaining its DataBound state across PostBacks. The Linkbutton disappears from view because it is not bound to the page on every PostBack, so when the response is sent back to the client, it has nothing bound to it.
It sounds like the UpdatePanel is expecting the same (or similar) markup to be returned from the AJAX response as what is on the page already, so returning nothing for the repeater causes problems.
Try binding your repeater to the page/control in its
OnInit() method. This should allow the ViewState for the repeater to be loaded on every PostBack.