Deselect cells from a selected range of table rows

Deselect cells from a selected range of table rows

adrdgradrdgr Posts: 9Questions: 6Answers: 0

Hi team,

I have created a select all functionality that selects all table rows using the code below:

$.fn.dataTable.ext.buttons.All = {
text: 'All',
extend: 'selectAll',
className:'fred',
action: function ()
{
table.rows().select();
}
};

Now, I want to deselect one cell. I tried to use the 'selector' but it does not run properly:
select: {
style: 'multi',
selector: 'select-enabled'
}

Is there any other way to manage it?

Thank you

Answers

  • allanallan Posts: 63,237Questions: 1Answers: 10,418 Site admin

    To deselect a single cell, control click on it.

    Or if you want to do it via the API use row().deselect() providing a suitable selector for your row to row().

    Allan

Sign In or Register to comment.