copy_csv functionality for table data

copy_csv functionality for table data

amit48samit48s Posts: 1Questions: 0Answers: 0
edited August 2013 in General
I am using div inside that I have to datatables. For the lower datatable I want copy csv pdf buttons. If I dont apply the code for this things work fine, but as I apply the code for this it gives an error while running . While loading copy csv pdf buttons appear but as the full page loads they disappears the table which was coming properly earlier shrinks and it throws error if inspect the page "Uncaught TypeError: Cannot read property 'sWidth' of undefined" for jquery.dataTable.min.js

$(document).ready(function () {
$("#clientDeptResultTable").dataTable({
"aLengthMenu": [[25, 50, 100, -1], [25, 50, 100, "All"]],
iDisplayLength: 25,
"sPaginationType": "full_numbers",
"bJQueryUI": false,
"sDom": '<"H"Tlfr>t<"F"ip>',
"oTableTools": {
"aButtons": [
"copy", "xls", "pdf","print"
],
"sSwfPath": "/clientsiteaccess/ext/jquery/extras/TableTools/media/swf/copy_csv_xls_pdf.swf"
},
"aoColumns": [
{ "asSorting": [ "asc" ,"desc" ] },
{ "asSorting": [ "asc" ,"desc" ] },
{ "asSorting": [ "asc" ,"desc" ] },
{ "asSorting": [ "asc" ,"desc" ] },
{ "asSorting": [ "asc" ,"desc" ] },
{ "asSorting": [ "asc" ,"desc" ] }
]

});
});



Can anyone help in resolving this issue ?
Thanks

Replies

  • allanallan Posts: 63,213Questions: 1Answers: 10,415 Site admin
    Please link to a test case: http://datatables.net/forums/discussion/12899/post-test-cases-when-asking-for-help-please-read
This discussion has been closed.