Hi, I have a problem and I don’t know why it is I hope you can help me with this in advance, thank you very much.
I have a main grid that when expanding a row shows me a nested grid, I currently get the data from the nested grid and it works correctly but there is a big problem.
My question is:
How can I get the data from the nested grid when I expand a row using showfilterrow?
First I check my data and filter the pending data using showfilterrow, then expand a row to show the nested grid and finally I get the data from the nested grid but it makes me an error.
This is my code:
var array_detalle_subgrid = [];
$('#gvDatos').on('rowexpand', function(event) {
var args = event.args;
var rowBoundIndex = args.rowindex;
window.setTimeout(function() {
// This line is where I get an error
var nestedGridID = nestedGrids[rowBoundIndex][0].id
var rows_subgrid = $('#' + nestedGridID).jqxGrid('getrows');
array_detalle_subgrid = rows_subgrid;
console.log('rows >>', rows_subgrid);
console.log('Resultado nuevo array >>', array_detalle_subgrid);
}, 0);
});
This is the error:
Uncaught TypeError: Cannot read property '0' of undefined
Could you please provide me with an example to obtain the nested grid data using showfilterrow.
Thank you.