Export a table to PDF without a specific column
Export a table to PDF without a specific column
Hamster69
Posts: 4Questions: 2Answers: 0
Hi my code is;
$(document).ready( function () {
currentTable = $('#example').DataTable( {
dom: 'Bfrtip',
buttons: [{
extend: 'pdfHtml5',
}]
});
});
currentTable.column( 1 ).visible( allDeviceSelected );
when I export it, the column 1 appear in the pdf.
How can I export the table without that specific column?
This question has an accepted answers - jump to answer
This discussion has been closed.
Answers
You need to use the
columns
option of theexportOptions
to control which columns are included in the export. There is an example of that here.Allan
It works.
thanks allan