DT2.0 and Excel BTN 3.0.1 - Columns rearrange with headers not working
DT2.0 and Excel BTN 3.0.1 - Columns rearrange with headers not working
Hi, I have updated to DT2.0, and I've noticed when I export to excel my columns data is OK, but the headers are in positions like in my DT.
example:
exportOptions: { columns: [28, 1, 2, 7, 8, 14, 15, 16, 17],...
The data is from column 28 but header from column 0
Kind regards
Jack
Answers
Yes, there appears to be a problem with a custom column ordering of the data due to the complex header support I'm afraid. I've got that on my list to look at.
I'm not yet sure if I consider it a DataTables bug or Buttons / export bug! DataTables doesn't provide the column header data in anything but data order, which is by design and anything else might be difficult. But it can do out of sequence data.
Allan
Thank you for your comment.
I plan to do it this way below. Have you better idea?
Not really - other than for me to resolve the underlying question
If that works for you, got with that for now.
Allan
OK thank you.
If it helps, I updated from /dt-1.11.3/b-2.0.1/ where all was working OK.