checking if the datatable is loaded

checking if the datatable is loaded

fitsum80fitsum80 Posts: 17Questions: 0Answers: 0
edited July 2011 in General
I am working with large data set by using the datatables server-side processing. Everything seems working great but I would like to show my own customization "loading wait.." message while the data is loading. Is there any way I can check if the datatable ajax request completely loaded, so I can hide the message?

Thanks in advance.

Replies

  • fbasfbas Posts: 1,094Questions: 4Answers: 0
    yes, there is a callback functions that DataTables will call when done with the data transfer from server and has finished drawing:

    fnDrawCallback (http://datatables.net/ref). this callback is good for non-server side code too, for any event after a draw (this is called after fnRender, and after fnRowCallback)

    you might look into fnPreDrawCallback. I'm not totally sure if fnPreDrawCallback is called before or after fnServerData, but I think it's after (and obviously before the drawing)
  • fitsum80fitsum80 Posts: 17Questions: 0Answers: 0
    Thanks fbas! That is exactly what I was looking for.

    Fitsum
This discussion has been closed.