Is redraw() necessarily required after applying fnUpdate() with redraw = false

Is redraw() necessarily required after applying fnUpdate() with redraw = false

mirshmirsh Posts: 4Questions: 0Answers: 0
edited June 2013 in General
Hi,

I have a datable. In my javascript routine, I am getting hold of the datatables data via fnGetData(), then updating a specific cell (replacing content with updated content updated content) using:

fnUpdate("updated content", rowIndex, cellposition, false, false ).

As you can see, I am explicitly prohibiting the table redraw.
The update to the desired column is made successfully, and I am even able to sort on that column without issues.

Is there a need to call the Redraw?

Just to provide some background. Without redraw set to FALSE, IE8 was grinding to a halt on this process as there are a good number of updates being carried out. I have read that its advisable in such scenarios to simply do a redraw at the end, however, in my case it seems that the redraw is not required?

I am using :

* @version 1.9.4
* @file jquery.dataTables.js

Regards
mirsh

Replies

  • allanallan Posts: 63,516Questions: 1Answers: 10,472 Site admin
    > Is there a need to call the Redraw?

    Yes - the filtering data is not updated. You can't filter on your new data.

    The fact that sorting works is a little coincidental as well :-).

    > E8 was grinding to a halt on this process as there are a good number of updates being carried out.

    Just call fnDraw after you have done all over your updates then, rather than redrawing every single time :-)

    Allan
This discussion has been closed.