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 Developer Forum    Comments List
Upload Images   @Reply   Bookmark    Link   Email   Next Unseen 
Passing Value Between Tabs
Dg Ewing 
     
4 years ago
I have a form with 2 tabs ( I know RR doesnt like tabs) the first tab is a continuous form, and when i select a record on it I want to open a 2nd form on the next tab with all the records that have the ID value from the first tab.

I have tried a gaggle of ways and I cant get any to work
Dg Ewing OP  @Reply  
     
4 years ago

Richard Rost  @Reply  
          
4 years ago
I hate tabs. I prefer side-by-side subforms. But if you MUST keep it with tabs, and nobody else has a solution, let me know in a couple days and I'll figure something out for you. I don't use tabs. I don't like them. So I don't know off-hand how to do this without experimenting.
Kevin Robertson  @Reply  
          
4 years ago
I rarely use Tabs so took a little figuring out. See screenshot and change the names where necessary.
Kevin Robertson  @Reply  
          
4 years ago

Kevin Robertson  @Reply  
          
4 years ago
Sorry, forgot to put in screenshot - set the Link Master/Child fields of the sub form on page 2 to your ID field.
Dg Ewing OP  @Reply  
     
4 years ago
Thanks Kevin,

Let clarify:  
1.  is your TabF the "master form" name or the tab control name?.
2. see pic wrt unbound customerID ( I change names so that I dont confuse my self)...I created an unbound on the subform which updated as I moved from record to record.....but I could never get the value "out of" the subform.
Dg Ewing OP  @Reply  
     
4 years ago

Dg Ewing OP  @Reply  
     
4 years ago
The unbound fields are SFAdventureID (it works and is on the subform)
MFAdventureID is on the mainform and I could never get it to recognize any of my code....Me. and Forms! etc...
Dg Ewing OP  @Reply  
     
4 years ago
Private Sub Form_Current()
    Forms!AdventureT_Frm!AdventureID = AdventureID
    ' 1. Subform name above
    ' 2. Forms!Adventure_TabFrm!AdventureID = AdventureID (this is the Mainform name)
    ' 3. Forms!TabForm!AdventureID = AdventureID (this is the tab control  name)
    ' All gave the same warning cannot fine form name
    MsgBox AdventureID
End Sub
Dg Ewing OP  @Reply  
     
4 years ago
Geez, after I removed my code in the MFAdventureID , then the on current updated my MFAdventureID,  so the first step is now working,   I have an unbound  with the ID value from the tab 0 ,,  I do not understand

forms!Adventure_TabFrm! {what is Tab1 in your code}....tab1.pages.item(1).SetfFocus.   and what is item(1)....not sure of the logic of getting to  the 2nd tab (tab1 ??) and then selecting records based on MFAdventureID (unbound value)
Dg Ewing OP  @Reply  
     
4 years ago

Kevin Robertson  @Reply  
          
4 years ago
Tab1 is the name of my Tab Control.
Item(1) is the second page (Tab).

They are zero-based meaning:
   The first tab has an index of 0
   The second tab has an index of 1
   ...and so on.
Dg Ewing OP  @Reply  
     
4 years ago
Ok, I subsisted my tab control name and now the tab1 (2nd tab) opens but it is at the first record and not using the unbound filed ID value to select records....

and I am still getting the "cant build a link between unbound forms".....
Dg Ewing OP  @Reply  
     
4 years ago
Kevin, Thanks I have it working now.  I misunderstood your instruction:
"Sorry, forgot to put in screenshot - set the Link Master/Child fields of the sub form on page 2 to your ID field."
the Link Master should reference the unbound "ID" field name which in my case is MFAdventureID.

again thanks , I think I am cooking in oil now.
Richard Rost  @Reply  
          
4 years ago
I'm glad Kevin got you working because I hate tabs.

Did I mention... I hate tabs? :)

This thread is now CLOSED. If you wish to comment, start a NEW discussion in Access Developer 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 5:08:59 PM. PLT: 0s