Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Page Scroller

Status
Not open for further replies.

Gatorajc

MIS
Mar 1, 2002
423
US
How would I go about making only x amount of records show out of Y records on a page and have buttons to move to the next page.

For example. So 100 records come out of a DB. I only want 25 to display per page. AJ
I would lose my head if it wasn't attached. [roll1]
 
Hi ...
its easy ... you just have to define Pagesize and cachesize for your Recordset and then set your absolut page to the page number which you want :

Pagesize = 25
CurPage = 2

RS.CacheSize = PageSize
RS.MoveFirst ()
RS.PageSize = PageSize

TotalPages = cInt(RS.PageCount)
If CurPage > TotalPages Then
CurPage = TotalPages
End IF

'Set the absolute page
RS.AbsolutePage = CurPage
----
TNX.
E.T.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top