Computer Learning Zone CLZ Access Excel Word Windows

Never follow the crowd, go where it's empty.

-Arnold Schwarzenegger
 
Home   Courses   TechHelp   Forums   Help   Contact   Merch   Join   Order   Logon  
 
Back to Access Payables Seminar    Comments List
Upload Images   @Reply   Bookmark    Link   Email   Next Unseen 
DoCmd GoToRecord
Ashlyn M Talley 
    
5 years ago
I'm having a bit of a tug of war trying get a label that I click on one form and then have it open another form using the Where condition.

I'm trying to pass the string value of a field on the current form frm_Speech that field in a combo box ServiceProvider.Column(0) to then open my next form frm_Orgn-temp to that specific records. My message box lets me know I have the right value but when I "OK" out of the message box I get a syntax error missing operator?

Private Sub ProviderLabel_Click()    
    MsgBox ServiceProvider.Column(0)    
    DoCmd.OpenForm "frm_Orgn-temp", , , "OrgnName=" & ServiceProvider.Column(0)  
End Sub
Alex Hedley  @Reply  
           
5 years ago
Change
DoCmd.OpenForm "frm_Orgn-temp", , , "OrgnName=" & ServiceProvider.Column(0)
To
DoCmd.OpenForm "frm_Orgn-temp", , , "OrgnName='" & ServiceProvider.Column(0) & "'"

Presuming OrgnName is a string?
Alex Hedley  @Reply  
           
5 years ago
Ashlyn M Talley OP  @Reply  
    
5 years ago
Hi Alex, nailed it!... Yes, OrgnName is a string. Thank you so much for not only the syntax solution but pointing me to the "Concatenation & the Double-Double Quote" video. So can't wait for the day when I can take command of VBA instead of feeling it to be a bit more mystery than solution. Thanks again!
Alex Hedley  @Reply  
           
5 years ago
Happy to help
Just takes practice :)

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

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 5:00:44 AM. PLT: 1s