Data table horizontal scroll
Data table horizontal scroll
Here is my datatable declaration. I have a table n number of columns some times it will come just two column that time also scoll will enable. It will make some irritating table. How to avoid scroll when it dont needs and i want fixed column of first column.
var shTable = jQuery('#example').DataTable({
scrollX: true,
scrollCollapse: true,
bScrollAutoCss: false,
paging: true,
responsive: true,
aaSorting : []
});
This question has an accepted answers - jump to answer
Answers
When DataTables doesn't need to scroll - it shouldn't. For example: http://live.datatables.net/nuqipoqe/1/edit .
Allan
i am using fixed column plugin. So automatically table scroll will come. My table have dynamic columns. so some times i dont need fixed column(its horizontal scrolling feature). just two column there but it has scroll. how to prevent this?
Can you link to the page please? FixedColumns shouldn't "activate" if scrolling isn't being used: http://live.datatables.net/nuqipoqe/2/edit .
Allan