Paging: get total number of pages

Hi,
i am sorry if my question is stupid but looking in this page i cant find how to get the total numbers o pages.

http://docs.dhtmlx.com/doku.php?id=dhtmlxgrid:paging

I have to write in the tool bar 1 of [TOTAL pages]

Thank you.

You may try to use the following code:

var total=mygrid.getRowsNum(); var pageSize=mygrid.rowsBufferOutSize var pageNum=total/pageSize

Thank you.

:slight_smile: