PageCount

This property indicates how many pages of data the recordset contains.

Syntax

recordset.PageCount

Remarks

Use the PageCount property to determine how many pages of data are in the Recordset object. Pages are groups of records whose size equals the PageSize property setting. Even if the last page is incomplete, because there are fewer records than the PageSize value, it counts as an additional page in the PageCount value. Set the property to -1 (adUnknown) when the size of the recordset is not determined.

For more information about page functionality, see the PageSize and AbsolutePage properties.