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 
Access VBA requery subform
Robert Stoner 
    
5 years ago
First off I hope I explain this well enough for someone to understand what I am trying to do. I have a form with a sub form then a second sub form.  on the second sub form I have a combo box and have set up NotInList.  The SQL works fine but when i try to Requery the combo box then set the value to the newly add row it fails to do anything.

things I have tried:
Me.comboName.Requery figured this would not work since it was in a subform.
Forms!secondSubFormName!comboName.Requery was hopeful but no luck.
Forms!mainFormName!subFormName!secondSubFormName.comboName.Requery still not luck tried with and with out [].
Forms!mainFormName.Form!....

Thanks for any Help to get me back on track.
Adam Schwanz  @Reply  
            
5 years ago
what about Forms!SubformName.Requery?
Robert Stoner OP  @Reply  
    
5 years ago
You mean Request the form itself and not just the combo box.  I thought about it but I would still have the problem of setting the combo box to the new record.
Robert Stoner OP  @Reply  
    
5 years ago
Lol replied from my phone and auto text attacked again. Requery not Request.
Robert Stoner OP  @Reply  
    
5 years ago
It seems when I copied a snippit of code it had an error handler that was suppressing an error code.  Thanks again for the reply.
Richard Rost  @Reply  
          
5 years ago
Hi Robert. Glad you figured it out. I just want to add my two cents: I really, REALLY hate OnNotInList. I cover it extensively in my old Access 324 class. There's a reason why I haven't covered it yet in the new Developer course... because I hate it. It glitches constantly. I personally prefer a button or double-click event to add a new item to a combo or list box. Then you just refresh the list when the form closes. Works much more reliably.

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: 5/6/2026 12:04:30 PM. PLT: 0s