Quantcast
Channel: DataTables 1.10 — DataTables forums
Viewing all articles
Browse latest Browse all 2364

Build a DataTable at runtime

$
0
0

Is it possible to build a DataTable at runtime?

This is my markup:

<table class="display compact" id="MY-TABLE" style="width:100%">
</table>

This is the JavaScript constructor call:

tblMine = $('#MY-TABLE').DataTable();

When the call to the constructor executes, I get this error:

jquery.dataTables.js:5856 Uncaught TypeError: Cannot read property 'aDataSort' of undefined

I do not know either the row count or number of columns until runtime.

TIA.


Viewing all articles
Browse latest Browse all 2364

Trending Articles