I am trying to get all the repeaters selected by the checkboxes of the repeater element just before moving the page (pagination) and storing them in some place.
foreach (RepeaterItem ri in rpt.Items)
{
CheckBox box = (CheckBox)ri.FindControl("chkBox");
if (box.Checked)
{
...
}
}
The problem is where can I call this function? I tried calling it from ObjectDataSource1_Selected (I use objectdatasource to populate the repeater) and ObjectDataSource1_Selecting, but rpt.Items.Count is also 0.
rpt_PreRender (), returns the correct number of elements, but this happens before the checkboxes are selected, and not after.
What can I do?
lupital
source
share