Free Lessons
Courses
Seminars
TechHelp
Fast Tips
Templates
Topic Index
Forum
ABCD
 
Home   Courses   TechHelp   Forums   Help   Contact   Merch   Join   Order   Logon  
 
Back to Access Forum    Comments List
Upload Images   @Reply   Bookmark    Link   Email   Next Unseen 
Only filtered records
Jeff Bartuch 
     
3 years ago
Hello

I have a list form that when a record is selected can open a detail form. With Kevin's help I was able to get the detail form to open at the selected record but also navigate to the next or previous record.

I really like the larger navigation controls this code offers, but I got it to display the list form's recordset with the code below, but when I move either forward or back through the records it is using the entire recordset instead of what is filtered on the list form.

Private Sub Form_ApplyFilter(Cancel As Integer, ApplyType As Integer)
     Forms!TicketSearchListF.Recordset.MoveLast
End Sub


Private Sub Form_Current()
     Dim db As Database
     Dim rs As Recordset

     Set db = CurrentDb
     Set rs = Forms!TicketSearchListF.Recordset

     RecCountBox = rs.AbsolutePosition + 1 & " of " & rs.RecordCount

     Set rs = Nothing
     Set db = Nothing
End Sub


What do I need to do to not only display the recordset in the RecCountBox text box on the form, but also only move to those records when the forward or back arrow(s) are pressed on the form?
Jeff Bartuch OP  @Reply  
     
3 years ago

Jeff Bartuch OP  @Reply  
     
3 years ago
Correctly displays filtered recordset when the detail form is opened from the list form, but when I move forward or back it moves through all of the records.
Alex Hedley  @Reply  
           
3 years ago
What's the code in your move button(s)?
Jeff Bartuch OP  @Reply  
     
3 years ago
Good question Alex. The forward and next buttons as well as the go to first/last buttons just have a the wizard macro set to them.

This thread is now CLOSED. If you wish to comment, start a NEW discussion in Access Forum.
 

Next Unseen

 
New Feature: Comment Live View
 
 

The following is a paid advertisement
Computer Learning Zone is not responsible for any content shown or offers made by these ads.
 

Learn
 
Access - index
Excel - index
Word - index
Windows - index
PowerPoint - index
Photoshop - index
Visual Basic - index
ASP - index
Seminars
More...
Customers
 
Login
My Account
My Courses
Lost Password
Memberships
Student Databases
Change Email
Info
 
Latest News
New Releases
User Forums
Topic Glossary
Tips & Tricks
Search The Site
Code Vault
Collapse Menus
Help
 
Customer Support
Web Site Tour
FAQs
TechHelp
Consulting Services
About
 
Background
Testimonials
Jobs
Affiliate Program
Richard Rost
Free Lessons
Mailing List
PCResale.NET
Order
 
Video Tutorials
Handbooks
Memberships
Learning Connection
Idiot's Guide to Excel
Volume Discounts
Payment Info
Shipping
Terms of Sale
Contact
 
Contact Info
Support Policy
Mailing Address
Phone Number
Fax Number
Course Survey
Email Richard
[email protected]
Blog RSS Feed    YouTube Channel

LinkedIn
Copyright 2026 by Computer Learning Zone, Amicron, and Richard Rost. All Rights Reserved. Current Time: 4/30/2026 9:06:45 AM. PLT: 0s