jQWidgets Forums

jQuery UI Widgets Forums Grid Vertical Scrollbar in NestedGrid

This topic contains 9 replies, has 3 voices, and was last updated by  Mr.Moo 9 years, 6 months ago.

Viewing 10 posts - 1 through 10 (of 10 total)
  • Author
  • Vertical Scrollbar in NestedGrid #70680

    pedro_prt
    Participant

    I made a nested grid with an ajax call to fill the grid.
    Everything is ok but the vertical scroll bar is not visible.

    Main Grid
    $(“#div_planilha_003_datagrid”).jqxGrid({
    width: 798,
    height: 400,
    source: dataAdapter,
    rowsheight: 21,
    altrows: true,
    rowdetails: true,
    initrowdetails: initrowdetails,
    rowdetailstemplate: { rowdetails: “<div id=’grid_003_detalhes’ style=’margin: 3px;overflow: auto;’></div>”, rowdetailsheight: 100, rowdetailshidden: true },
    columnsresize: true,
    selectionmode: ‘singlerow’,
    enablehover: true,
    columns: [
    { text: ‘Hora’, datafield: ‘ida_h_saida’, cellsrenderer: rend_cell, width: 60 },
    { text: ‘Rota’, datafield: ‘rota’, cellsrenderer: rend_cell, width: 300 },
    { text: ‘Pax’, datafield: ‘r_pax_cli’, cellsrenderer: rend_cell, width: 55 },
    { text: ‘Vagas’, datafield: ‘r_vagas’, cellsrenderer: rend_cell, width: 55 },
    { text: ‘Local de saída’, datafield: ‘ida_local_saida’, cellsrenderer: rend_cell, width: 300 }

    ]

    })

    Sub Grid

    var detalhesAdapter = new $.jqx.dataAdapter(source);
    if (grid != null) {
    grid.jqxGrid({
    source: detalhesAdapter,
    width: ‘100%’,
    height: ‘100%’,
    rowsheight: 21,
    columns: [
    { text: ‘Nome’, datafield: ‘id_passageiros’, width: 200 },
    { text: ‘Pax’, datafield: ‘pax’, width: 100 }
    ]
    });
    }

    Is there any property to set the scrollbars ?
    In the main grid they are shown if the grid is bigger than the container.

    thanks

    Vertical Scrollbar in NestedGrid #70694

    Peter Stoev
    Keymaster

    Hi pedro_prt,

    May be your Nested Grid’s Width is higher than your Grid’s width and that’s the issue here. Set less width to your nested grid.

    Best Regards,
    Peter Stoev

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

    Vertical Scrollbar in NestedGrid #70743

    pedro_prt
    Participant

    Hi

    My main grid is 798 width and the sub-grid is 250.
    I tried all possible scenarios. Different column widths, autoheight on/off, different sub-grid widths, etc.
    In all situations, if the sub-gris is heigher than the rowdetailsheight on the main-grid it’s impossible to see the hidden rows. If I try to scroll down the sub-grid width the keyboard, also doesn’t scroll.

    Hope you have a workaround because this grid is almost exactly what I need.

    I’m trying this grid width the 30-day fully functional evaluation version of jQWidgets (jQWidgets v3.8.0 (2015-Apr)). I don’t know if in others versions this situation works.

    Tks

    Pedro Oliveira

    Vertical Scrollbar in NestedGrid #70756

    Peter Stoev
    Keymaster

    Hi Pedro,

    “if the sub-gris is heigher than the rowdetailsheight on the main-grid it’s impossible to see the hidden rows” – of course No. It should be with less height than the rowdetailsheight.

    Best Regards,
    Peter Stoev

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

    Vertical Scrollbar in NestedGrid #70762

    pedro_prt
    Participant

    Works Great

    I didn’t set the height of the sub grid or in other situation I set it to 100%.
    Now I set the sub grid height to 145 and the rowdetailsheight to 150 and it works perfectly.

    Thanks for your help

    Vertical Scrollbar in NestedGrid #70764

    Peter Stoev
    Keymaster

    Thanks for the update, Pedro.

    Best Regards,
    Peter Stoev

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

    Vertical Scrollbar in NestedGrid #76577

    Mr.Moo
    Participant

    I have a similar situation but I simply cannot get the scroll bars to display. I have set my rowdetailsheight: 150 in the rowdetailstemplate and set the height of the sub-grid to 140. What am I missing?

    grid.jqxGrid({ altrows: true, source: detailsAdapter, width: 850, autoheight: true, height: 140, columns: […]}) ;

    and

    rowdetailstemplate: { rowdetails: “<div id=’grid’ style=’margin: 0px;’></div>”, rowdetailsheight: 150, rowdetailshidden: true } …

    So any help would be appreciated.

    Vertical Scrollbar in NestedGrid #76578

    Peter Stoev
    Keymaster

    Hi Mr.Moo,

    When autoheight is set to true, scrollbars should not be displayed.

    Best Regards,
    Peter Stoev

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

    Vertical Scrollbar in NestedGrid #76582

    Mr.Moo
    Participant

    Thanks Peter,

    I have removed this attribute in both my table definitions but for me, no effect!

    So if you have any further thoughts…


    Moo

    Vertical Scrollbar in NestedGrid #76601

    Mr.Moo
    Participant

    Maybe if I had of been paying attention I would have realised that I needed to adjust the width of the nested grid and it wouldn’t have needed to have been pointed out to me!

    So thanks again to everyone for the answer.


    Moo

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

You must be logged in to reply to this topic.