Categories | Question details Back To List | ||
pagination in dhtmlxgrid i want to use pagination like this : 1-15|16-30|31-45 please help to achieve this type of pagination. it's urgent. Answer posted by Support on Oct 15, 2008 01:54 The command grid.enablePaging( true, 15, 3, .... ) added to the grid init code will split grid on pages, each of which will contain 15 rows ( dhtmlxgrid_pgn.js need to be used ) To create custom paging view - please check http://dhtmlx.com/docs/products/dhtmlxGrid/doc/articles/Custom_paging.html#grid_art_custpaging Answer posted by shweta on Oct 15, 2008 02:31 i want to paging view like 1-15|16-30|31-45 plz help me Answer posted by Support on Oct 15, 2008 04:45 Pre-defined paging skins don't support such rendering of paging info, you need to create your custom paging skin Check the link above, "Creating a custom skin" section Answer posted by Support on Oct 15, 2008 04:47 Technically you can just use a line of HTML on the page as <span onclick="grid.changePage(1)">1-15<span>|<span onclick="grid.changePage(2)">16-30<span>|<span onclick="grid.changePage(3)">31-45<span> Answer posted by shweta on Oct 15, 2008 20:35 thanx...and what shuld i write in grid.changePage(1) function .Plesae let me know..... it's very urgent Answer posted by Support on Oct 16, 2008 03:21 changePage is built in functionality of grid, you can call grid.changePage(n) to show page n in grid. In the code snippet above just use the correct grid reference name and changePage will be mapped to the grid's method, which will do all work Answer posted by shweta on Oct 17, 2008 05:18 tahnks..for that..... but 1-15|16-30|31-45 shuld comes dynamically acc to data size......and on that i need that onclick event
plz reply!!!! Answer posted by Support on Oct 17, 2008 06:50 You can catch loading end moment ( onXLE event ) , get total count of rows ( grid.getRowsNum ) and form necessary HTML on the page. |