fnDrawCallback issues

fnDrawCallback issues

ChrisGChrisG Posts: 29Questions: 0Answers: 0
edited August 2013 in DataTables 1.9
I might be confused as to how fnDrawCallback works... Is this being called after everything is drawn? I'm trying to force scroll to the bottom of the page with window.ScrollTo inside fnDrawCallback. The problem is that if I need to update the table to display like 500 rows, it seems to finish the scroll before it finishes drawing all the rows... Which leaves it scrolled down a bit but not all the way to the bottom.

Is there some way to perform an action after absolutely all of the rows have been displayed and the table is finished with everything?

Replies

  • allanallan Posts: 63,498Questions: 1Answers: 10,471 Site admin
    > Is this being called after everything is drawn?

    Yes. Right at the end of the draw function he last thing it does is call the draw callback: https://github.com/DataTables/DataTables/blob/master/media/js/jquery.dataTables.js#L1571 .

    To be able to say any more than that, I think I'd need a link to a test case.

    Allan
This discussion has been closed.