Fixed Header th columns miss aligning with td columns
Fixed Header th columns miss aligning with td columns
Durgaprasad Nakka
Posts: 5Questions: 2Answers: 0
i have a datatable with x,y scrollbars table header columns are not aligning with table body columns in IE browser other browsers it is working fine.
I am using nowrap class need text to be always in single line, with drop down selection of changing data even alignment even going worst, tried below scripts
$($.fn.dataTable.tables(true)).DataTable().columns.adjust().draw()
but not resolved
This discussion has been closed.
Answers
The FixedHeader docs state this:
You can also look at the Compatibility Matrix.
Kevin
Thanks kthorngren,
in other pages also i have same scenario where it is working as expected, in this case only difference is my
1) table inside tabs and collapse panel
2) loading data as per drop down selection using $('#myTable').DataTable().destroy(); in onchange function.
3) i have multiple tables in one page(html)
suggest if i am missing anything
You can try
columns.adjust()
after displaying the panel.Not sure without seeing it.
Normally this is not a problem.
As the docs state there is a known incompatibility with FixedHeader and Datatables scrolling features. The problem is due to how they are architected. They don't always work well together. You can remove one of them from your Datatable config.
Kevin
kthorngen,
i used columns.adjust() API here is my code please suggest
CreateEmptyGuarateeDetailsGrid(gridName, gridContainer, gridID, gridHeadID, gridBodyID);
Hi @Durgaprasad Nakka ,
We're happy to take a look, but as per the forum rules, please link to a test case - a test case that replicates the issue will ensure you'll get a quick and accurate response. Information on how to create a test case (if you aren't able to link to the page you are working on) is available here.
Cheers,
Colin