updating _iDisplayLength to -1 reflects on number of rows but not reflecting on dropdown
updating _iDisplayLength to -1 reflects on number of rows but not reflecting on dropdown
I am creating a datatable (monTable) with the following overriden options:
"bLengthChange" : true,
"aoColumnDefs" : [ {
"bVisible" : false,
"aTargets" : [ 10, 11, 12, 13, 14, 15, 16, 17, 18, 19 ]
} ]
When my table refreshes, i do the following in my callback:
var oSettings = monTable.fnSettings();
oSettings._iDisplayLength = -1;
oSettings._iDisplayStart = 1;
monTable.fnDraw(true);
It draws the table fine and shows all records, but the dropdown still shows 10 i..e the value when the table first loads. How could i change it to reflect it to All
"bLengthChange" : true,
"aoColumnDefs" : [ {
"bVisible" : false,
"aTargets" : [ 10, 11, 12, 13, 14, 15, 16, 17, 18, 19 ]
} ]
When my table refreshes, i do the following in my callback:
var oSettings = monTable.fnSettings();
oSettings._iDisplayLength = -1;
oSettings._iDisplayStart = 1;
monTable.fnDraw(true);
It draws the table fine and shows all records, but the dropdown still shows 10 i..e the value when the table first loads. How could i change it to reflect it to All
This discussion has been closed.
Replies
http://datatables.net/ref#aLengthMenu
I do have the menu set with the All option, but when I try to change the oSettings._iDisplayLength = -1;
for my table in JS, it doesn't change the dropdown to reflect the changed value. However, the number of rows promptly change to showing All rows in the table
Thanks,
Andy.