Can I refresh the table data all at once?

Can I refresh the table data all at once?

forthekillforthekill Posts: 1Questions: 1Answers: 0

I am using Editor to allow DataTable editing, and it submits data to my server object to update my database.

I am then getting the new data from the database table and sending it to my page, and I want to refresh the DataTable.

Is there a way to add all of the JSON data to the table at once like you do in initialization? Or do I have to clear the table, then do addRow for each row in the data set before I do a redraw?

Something like this:

tickets.clear()
tickets.data = tableData;
tickets.draw();

Answers

  • colincolin Posts: 15,177Questions: 1Answers: 2,590

    The table should update automatically with the response from the server - see example here.

    It might be useful if you could explain in more detail about what you're trying to do, as it sounds like you shouldn't need to clear the table unless there's a specific reason to,

    Colin

Sign In or Register to comment.