Why am I not getting draw.dt events.

Why am I not getting draw.dt events.

wagswags Posts: 1Questions: 1Answers: 0

I am not receiving any 'draw.dt' events. I have the following code...

$('#board-table').dataTable({
    "paging": false,
    "scrollX": true,
    "autowidth": false,
    "searching": false,
    "ordering": false,
    "scrollY": '80vh',
    "info": false,
    fixedHeader: {
        header: true,
        footer: false

    },
    fixedColumns: {
        leftColumns: 2,
        heightMatch: 'auto'
    },

});


$('#board-table').on('draw.dt', function () {
    console.log( 'Redraw occurred at: '+new Date().getTime() );
});

The draw event handler code is directly from your documentation.

What am I doing wrong?

Answers

  • allanallan Posts: 61,985Questions: 1Answers: 10,162 Site admin
    edited April 2016

    Are you using DataTables 1.10 or newer? Please link to a test case, as requested in the forum rules, so the issue can be debugged. Your code above looks fine. (edit: typo)

    Allan

This discussion has been closed.