I have a .NET repeater
control that is data-bound
to a List. As part of the Repeater's Item Collection
, I have a "Remove Button" that effectively removes this current List element.
This works, in code-behind I can successfully remove an item from the datasource
of the Repeater.
My problem is this : when I reset the updated datasource
and call MyRepeater.DataBind()
again, the Repeater interface does not refresh with the Item removed.
I am looking for the event to essentially redraw or refresh the Repeater based on the updated List. Thanks for any pointers or examples.
You need to call the 'DataBind' method on your datasource, then call 'DataBind' on your Repeater control.
Are you feeding the refreshed data source?
If you are setting data source in code-behind, you need to set it with refreshed data then call DataBind method.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With