Export button make incorrect order in headers
Export button make incorrect order in headers
NIkflipflop
Posts: 3Questions: 2Answers: 0
Export button Headers wrong order if use columns order in revert order
buttons: [
{
extend: 'excelHtml5',
exportOptions: {
columns: [2,1 ],
stripNewlines: false,
orthogonal: "export"
},
}
],
Will result
Header 1, Header 2
Value 2, Value 1
Order 1.* version all work correct
This question has an accepted answers - jump to answer
Answers
The export will happen with the columns in the order that they are in the DataTable, not the order of the
columns
array for the button. That is how the columns selector operates.Allan
But value come in same order like columns instead header,
Oh - I had missed that. Thanks for the follow up. I'll take a look into it next week.
Allan