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 
Name of Query on Form
Stacey Bagaglio 
     
2 years ago
I have a form 'Order Status Form' that uses the 'On Click' Macro Builder action: OpenForm and filters the data using an existing query. There are 12 different queries a user can run. Is there an expression, code or vba linked to the 'On Load'  to capture the name of the query run so I can display it in a field on the form?
Sami Shamma  @Reply  
             
2 years ago
What you are asking to do is double, please provide more information.
John Davy  @Reply  
         
2 years ago
Hi Stacey

Take a look at qrydefs. That will get you the list of the queries. You can manage the list in a listbox or combo box and do whatever you need for the user. Take a look at Rick's AI builder in the globalMod.
HTH
John
Richard Rost  @Reply  
           
2 years ago
You could set the value of a text box equal to whatever query the user selected. Is that what you're trying to do?
Stacey Bagaglio OP  @Reply  
     
2 years ago
Yes. Trying. The little bit of code I figured out so far only gives me the name of the form (which is displayed at the top of the form already). Haven't figured out code yet to show the actual query.
Kevin Robertson  @Reply  
          
2 years ago
TextBoxName = Me.RecordSource
Stacey Bagaglio OP  @Reply  
     
2 years ago
Kevin, that code Me.RecordSource is the one I already learned and tried. It returns the name of the control query. Not the name of the filter query that is called when the macro runs.

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/7/2026 2:24:37 AM. PLT: 1s