jQWidgets Forums

jQuery UI Widgets Forums Grid Automatically determine page size?

This topic contains 4 replies, has 3 voices, and was last updated by  Makla 11 years, 4 months ago.

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
  • Automatically determine page size? #31296

    realtek
    Participant

    Hi,

    When paging is enabled, how can I set the pagesize to be automatic? So if the grid is set to 100% height and width, and no pagesize is set for example… I would like it to just fill with as many rows as possible for the page?

    Thanks

    Automatically determine page size? #31298

    Dimitar
    Participant

    Hello realtek,

    Unfortunately, this functionality is not supported by jqxGrid.

    Best Regards,
    Dimitar

    jQWidgets team
    http://www.jqwidgets.com/

    Automatically determine page size? #31299

    realtek
    Participant

    OK Thanks Dimitar, I actually just worked out my own solution that might help people!

    //Automatically Set Page Height
    var height = $(“#jqxgrid”).height()-128;
    total = height/26;
    size = Math.round(total);
    $(“#jqxgrid”).jqxGrid({pagesize : size});

    I have height – 128 because I have the toolbar enabled on my grid, so you need to remove all the around the possible area for rows.

    Hope it helps someone!

    Thanks

    Automatically determine page size? #31300

    realtek
    Participant

    There are some small issues that need ironing out such as the “pagesizeoptions” and the fact the browser could be resized but i’ll work on it.

    it would be good if this was supported out of the box because it seems quite logical and i’m sure many situations would benefit from it.

    Automatically determine page size? #47210

    Makla
    Participant

    Agree. This would be a nice feature.

Viewing 5 posts - 1 through 5 (of 5 total)

You must be logged in to reply to this topic.