I want horizontall scroll(automatically when I scroll the table horizontally) and fixed header, without vertical scroll on my dataTable. To be more precise, I'm achieving this only if property scrollY:300, if I set other value, it is not working. Here is my initialization of dataTabe:
this.table = new $('#mainTable').DataTable({
responsive: false,
paging: false,
searching: false,
lengthChange: false,
sorting:false,
pageLength: 200,
scrollY:300,
scrollX: true,
scrollCollapse: true,
fixedHeader: {
header: true,
},
})