I have an esDataSource control which a GridView control is bound to. The esDataSource handles the total record count as well as the current (20) rows that should be displayed when paging. Unfortunately, I am unable to show the count of this in my grid. for example, I want it to say "Showing records 20-40 of 684" in the footer of the gridview. does the esDataSource control return this property? How can I do this? I can't find it...I am sure hte answer is easy to you guys, I just dont know where it is.
Thank you,
Br
You can access the values needed to construct paging text in the esPostSelect event like so
protected void EsDataSource1_esPostSelect(object sender, EntitySpaces.Web.esDataSourceSelectEventArgs e) { var emps = e.Collection as EmployeesCollection; if (emps != null) { int count = emps.Count; int pageNumber = emps.Query.es.PageNumber; int pageSize = emps.Query.es.PageSize; } }
Regards, Scott Schecter EntitySpaces | Blog | Twitter