Hello,
I have a CMS repeater inside an update panel on my asp.net webforms front end code that gets populated from a webservice call that grabs data from my database. I've set EnablePaging="true" but the pagination just doesn't show up at all. I've tried setting page size and also the PagerControl-PagingMode to postback but to no avail.
Here's a sample of what I have:
<cms:CMSRepeater runat="server" ID="repeaterTest" OnItemCreated="ItemCreated" OnItemCommand="repeaterItemCommand" ItemType="WebServiceClient.Service.Data" EnablePaging="true" PageSize="25"> <HeaderTemplate> <table> <thead> <tr> <th>some header</th> <th>some header2</th> </tr> </thead> <tbody> </HeaderTemplate> <ItemTemplate> <tr> <td><%# Item.ID #></td> <td><%# Item.FirstName #></td> </tr> </ItemTemplate> <FooterTemplate> </tbody></table> </FooterTemplate> </cms:CMSRepeater>
Code behind:
protected void Page_Load(object sender, EventArgs e) { BindRepeater(); } private void BindRepeater() { var allData = // call to web service; repeaterTest.DataSource = allData; repeaterTest.DataBind(); }
Any help would be appreciated to get this rolling.
To haven't defined your pager templates. Better off setting everything in code behind if you're not using the standard webpart.
Is the pager template the unipager control? I thought if we enabled paging on the cms:Repeater it doesn't need to be set? None of the examples on Kentico documentation has a pager template as well?
Please, sign in to be able to submit a new answer.