Free Lessons
Courses
Seminars
TechHelp
Fast Tips
Templates
Topic Index
Forum
ABCD
 
Home   Courses   TechHelp   Help   Contact   Merch   Join   Order   Logon   Forums   
 
Home > Forums > Access Forum > Get Rid of Tabs by Shawn Hicks
Back to Access Forum    Comments List
Upload Images | @Reply | Bookmark | Link | Email | Next Unseen |
Get Rid of Tabs
Shawn Hicks 

6 years ago
I created a database for our Animal Control.  Everything was working fine until I changed up my form and started using tabs.  In the owner and animal tabs, I have a drop down where user I can select the owner and animal, and then it populates the fields within the tab.  It worked fine until I moved the fields to the tabs.  Now they won't populate.  Is there another code I should use, instead of "ME", when working within tabs?
Richard Rost  @Reply  
          
6 years ago
I really hate tabs. Can't stand them. I even say so in my Beginner and Expert classes numerous times: DON'T USE TABS! Why? When you start getting into more advanced stuff, like you're finding out, they become a nightmare to work with. I'd rather have multiple smaller forms, or have to scroll, than to use tabs. But, generally, if you drop a field, let's say FieldA in a tab, then it should behave like the rest of the controls on the form. Should. But sometimes it doesn't. Good luck! What's your code that does the populating?
Shawn Hicks OP  @Reply  

6 years ago
I must have missed that.  I was considering going back to just the form.  Here's the code for owner and animal:
Private Sub OwnerID_Change()
Me.LastName.Value = Me.OwnerID.Column(1)
Me.FirstName.Value = Me.OwnerID.Column(2)
Me.Address.Value = Me.OwnerID.Column(3)
Me.City.Value = Me.OwnerID.Column(4)
Me.State.Value = Me.OwnerID.Column(5)
Me.Zip.Value = Me.OwnerID.Column(6)
Me.Phone.Value = Me.OwnerID.Column(7)

End Sub

Private Sub AnimalID_Change()
Me.AnimalType.Value = Me.AnimalID.Column(1)
Me.OtherType.Value = Me.AnimalID.Column(2)
Me.PrimaryBreed.Value = Me.AnimalID.Column(3)
Me.SecondaryBreed.Value = Me.AnimalID.Column(4)
Me.PrimaryColor.Value = Me.AnimalID.Column(5)
Me.SecondaryColor.Value = Me.AnimalID.Column(6)
Me.Sex.Value = Me.AnimalID.Column(7)
Me.SpayNeut.Value = Me.AnimalID.Column(8)
Me.AniName.Value = Me.AnimalID.Column(9)
Me.DateofBirth.Value = Me.AnimalID.Column(10)
Me.Age.Value = Me.AnimalID.Column(11)

End Sub
Richard Rost  @Reply  
          
6 years ago
I don't see any reason why that shouldn't work. You've got a lot of extraneous stuff on there you don't need. You don't NEED to specify "Me" or "Value" in most cases.

FirstName = OwnerID.Column(2)

Should work just fine. Is the Combo Box in a tab or on the main form?
Shawn Hicks OP  @Reply  

6 years ago
Its on the same tab as the fields.  I'll try the simple code and see if that works.
Richard Rost  @Reply  
          
6 years ago
The changes in the code are actually meaningless to the computer - they're defaults. It just makes the VBA easier to read and write for you. Check the names of the fields. Make sure you didn't copy and paste them and end up with Control115 or something like that in the Name property.
Shawn Hicks OP  @Reply  

6 years ago
Tried the new code and it works now.
Richard Rost  @Reply  
          
6 years ago
Interesting. Logically, it's the same. Curious. Oh well. As long as it works. Reminds me of one of my favorite programmer pics:

Shawn Hicks OP  @Reply  

6 years ago
LOL, thats about right.  Thanks for your help!

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

Next Unseen

 
 
What's This?

 

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: 10/24/2026 6:12:57 AM. PLT: 2s