cannot load Javascript array of array in the datatable plug in. I am using datatable v1.9

cannot load Javascript array of array in the datatable plug in. I am using datatable v1.9

pkharvipkharvi Posts: 2Questions: 0Answers: 0
edited August 2013 in DataTables 1.9
Here is my Javascript datasource which is array of array.

[quote]
aaData
- [0]
- Action ""
- Activity Name "Name1"
- Contact "value"
- Due Date ""
- [1]
- Action ""
- Activity Name "Name2"
- Contact "value"
- Due Date ""
...etc
[/quote]


and Here is my datatable plug in
[code]
$('#tblMyTraining').dataTable({
"bPaginate": false,
"bFilter": false,
"bSort": true,
"bInfo": false,
"bAutoWidth": false,
"sScrollY": "200px",
"bScrollCollapse": true,
"bDeferRender": true,
"bProcessing": true,

"aaData": oData,
"aoColumnDefs": [
{ "aTargets": [ 0 ]
}],
"aoColumns": [
{ "mDataProp": "Action" },
{ "mDataProp": "Activity Name" },
{ "mDataProp": "Contact" },
{ "mDataProp": "Due Date" }


]

});
[/code]

[quote]
with this code the datatable is showing the following error
[code]DataTables warning (table id = 'tblMyTraining'):Requested unknown parameter 'Action' from datasource for row 0[/code]
[/quote]

Replies

  • allanallan Posts: 63,381Questions: 1Answers: 10,449 Site admin
    As noted, please link to a test case: http://datatables.net/forums/discussion/12899/post-test-cases-when-asking-for-help-please-read

    Allan
  • pkharvipkharvi Posts: 2Questions: 0Answers: 0
    Hey Allan - i have added the code in live datatables
    http://live.datatables.net/idinat/84/edit
This discussion has been closed.