Reputation: 5862
I have a Listview + Datapager and I wonder if there's some fancy solution to "duplicate" it and show the same datapager on top and bottom of the datagrid without using 2 different datapagers.
Thanx a lot
Upvotes: 0
Views: 3512
Reputation: 2230
in .NET4 you can put multiple pager element tags in the listview LayoutTemplate element
Upvotes: 0
Reputation: 2190
I've come across to that page searching for a similar solution for Gridview control. If you prefer using Gridview, there is a built-in solution .net framework. You can set PagerSettings.Position property to TopAndBottom to get pager control on top of and at the bottom of gridview control. You can see the MSDN documentation page for PagerSettings.Position here.
Upvotes: 1
Reputation: 5862
I've managed it using this approach:
http://www.codeproject.com/KB/custom-controls/mirror.aspx
I created an ascx user control that replicates any other control exactly as it is.
Upvotes: 0
Reputation: 49195
One of the dirty way could be replicate pager html using javascript. For example, using jquery:
$(document).ready(function() {
$('#topPager').append($('#bottomPager').html());
});
Where you have two divs - one empty placeholder div with id=topPager and another div with id=bottomPager containing pager control. Note that in case if events being added to pager elements such as links/anchors then you may use jquery clone method to clone pager element with events
Upvotes: 4