I\'m using jQuery Datatables. I want to change the height of the table whenever a user resizes the window. I\'m able to catch the window resize event which allows me to calculat
For DataTables 1.10:
$("#table").DataTable( { scrollY: '250px', scrollCollapse: true, paging: false, }); $('#table').closest('.dataTables_scrollBody').css('max-height', '500px'); $('#table').DataTable().draw();
When you changed CSS you must call draw().
draw()