PDA

View Full Version : GridPanel + automatic height + PagingToolbar?



Felicitus
17 Mar 2011, 12:41 PM
Hi,

is it possible to have a GridPanel with automatic height (i.e. it will show as many rows that fit into the current height of the panel) AND updating the pageSize of the PagingToolbar?

And if not with ExtJS3, how about ExtJS4?

thanks
Felicitus

conorarmstrong
17 Mar 2011, 4:49 PM
This has been asked many times before.

You will need to work out the limit param yourself from the grid height and row height, and then use this as a param. You also need to account for grid resizing (if it was included in a panel with fit layout for example) and adjust the limit then too. You will also need to consider the consequences on the page number if the rows per page changes - will you for example work out what page the old first record of the current page no appears on and load that or simply go for the easier option of jumping to page one on a resize.

Dont think this issue is addressed in extjs4, unless anyone knows otherwise???