PageCount
PageCount returns the total number of pages in report that is previewed in PDF. Use this function in a text object. 
                  
Syntax:
PageCount()
Example:
If the current page count is 6, yields: "The total number of pages is: 6".
The total number of pages is: PageCount().
                  
Note:
PageCount works for reports that are previewed in PDF only. HTML reports do not have multiple pages, so the PageCount returned will be: 1.