I have downloaded datatables jQuery plugin v1.9.4 and extracted the following style sheets and scripts files into my Visual Studio 2010 web project. Added following to my webform but for some reason the Export to excel, copy, print etc buttons are not showing
up. Rest of the table is fully functional. If some one has any idea on what's missing please let me know. Thanks
I tried following that example too but for some reason can't get it to work. If you were able to get it working and have working example then please let me know otherwise for now I just wrote a export method that exports all text in <table> tags to an Excel
file. Thanks
johnzee
Member
100 Points
139 Posts
No tool bar buttons in Datatables jquery plugin
Nov 07, 2012 12:32 AM|LINK
Hi,
I have downloaded datatables jQuery plugin v1.9.4 and extracted the following style sheets and scripts files into my Visual Studio 2010 web project. Added following to my webform but for some reason the Export to excel, copy, print etc buttons are not showing up. Rest of the table is fully functional. If some one has any idea on what's missing please let me know. Thanks
<link rel="stylesheet" href="Datatables/css/demo_table.css" type="text/css" />
<link rel="stylesheet" href="DataTables/css/TableTools.css" type="text/css" />
<link rel="stylesheet" href="DataTables/css/jquery-ui-1.8.4.custom.css" type="text/css" />
<script type="text/javascript" src="Datatables/js/jquery.js"></script>
<script type="text/javascript" src="Datatables/js/jquery.dataTables.js"></script>
<script type="text/javascript" src="DataTables/js/TableTools.js"></script>
<script type="text/javascript" src="DataTables/js/ZeroClipboard.js"></script>
$(document).ready(function () {
var oTable = $('#mytbl').dataTable({ "oLanguage": { "sSearch": "Search All Columns:" },
"bJQueryUI": true,
"sPaginationType": "full_numbers",
"oTableTools": {
"aButtons": [
"copy", "csv", "xls", "pdf",
{
"sExtends": "collection",
"sButtonText": "Save",
"aButtons": [ "csv", "xls", "pdf" ]
}
]
}
});
asteranup
All-Star
30184 Points
4906 Posts
Re: No tool bar buttons in Datatables jquery plugin
Nov 07, 2012 02:17 AM|LINK
Hi,
This is using swf file to do this operations. Have you setup the swf file properly. Check this link-
http://www.datatables.net/release-datatables/extras/TableTools/swf_path.html
Anup Das Gupta
Mark as Answer if you feel so. Visit My Blog
johnzee
Member
100 Points
139 Posts
Re: No tool bar buttons in Datatables jquery plugin
Nov 07, 2012 11:04 PM|LINK
I tried following that example too but for some reason can't get it to work. If you were able to get it working and have working example then please let me know otherwise for now I just wrote a export method that exports all text in <table> tags to an Excel file. Thanks
asteranup
All-Star
30184 Points
4906 Posts
Re: No tool bar buttons in Datatables jquery plugin
Nov 08, 2012 03:35 AM|LINK
Hi,
I dont have a working sample right now, but you may want to check this post-
http://growingtech.blogspot.in/2012/10/export-html-to-excel-using-jquery-and.html
Anup Das Gupta
Mark as Answer if you feel so. Visit My Blog
johnzee
Member
100 Points
139 Posts
Re: No tool bar buttons in Datatables jquery plugin
Nov 08, 2012 12:08 PM|LINK
Yes thanks I wrote some thing similar that exports the table into Excel.
-John