jQuery UI Widgets Forums DataTable setCellValue is not working after sorting/filtering

This topic contains 1 reply, has 2 voices, and was last updated by  Dimitar 7 years, 4 months ago.

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author

  • SJ


    I have a problem in Datatable. After filtering or sorting setCellValue method is not updating the selected row. The below code works fine when i select a row without filter/sort.

    $(‘#jqxbutton2’).click(function () {

    var selectedRowIndex = $(‘#table’).jqxDataTable(‘getSelection’);
    for (var i = 0; i < selectedRowIndex.length; i++) {
    $(“#table”).jqxDataTable(‘setCellValue’, selectedRowIndex[i][“uid”], ‘First Name’, ‘shweta’);



    Hi SJ,

    Thank you for your feedback. This occurs because the method setCellValue requires the row’s visible index as a first parameter, not the row’s id (that you get from getSelection). Unfortunately, there is no way to get a row’s index from its id in jqxDataTable, but this can be achieved using jqxGrid, a similar, but far more advanced widget. We suggest you try it out.

    Best Regards,

    jQWidgets team

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.