Hidden columns are shown when browser window is resized
Hidden columns are shown when browser window is resized
cbusuttil
Posts: 4Questions: 1Answers: 0
Hi Guys,
I'm encountering an issue with datatables having hidden columns. I'm using the function fnSetColumnVis to hide a column and it works perfectly, however when the browser window is being resized the hidden columns are being shown again. Can someone point me in the right direction please?
Best Regards,
Chris.
This question has an accepted answers - jump to answer
This discussion has been closed.
Answers
I never had problems with this code.
Hi neurofunk,
thanks for your reply. i'm actually using aoColumns, i tried using the bVisible: false option, however it wasn't working that's why i had to use fnSetColumnVis.
Sounds very much like you are using Responsive (although without a test case, as required by the forum rules, it is impossible to say for sure).
At the moment Responsive and column visibility are not compatible since Responsive itself is using the column visibility controls.
This is something I will be addressing in a future release of Responsive.
If you want columns to never be shown, use the
none
ornever
class - see documentation.Allan
Hi allan,
Many thanks for your feedback. You are right i'm using the Responsive, in fact i thought that it might be the cause of the issue. I'll take a look at the documentation you gave me and will let you know how it goes.
Chris.
Hi allan
Thanks a lot for your help, using the class never worked like a charm. Thanks once again.
Best Regards,
Chris.