Free Lessons
Courses
Seminars
TechHelp
Fast Tips
Templates
Topic Index
Forum
ABCD
 
Home   Courses   Seminars   Templates   TechHelp   Fast Tips   Forums   Help   Contact   Join   Order   Logon  
 
Home > Forums > Access
 
Access Forum


Back to Access Forum
 

Not Sure What Im Looking For Upload Images   Link  
Glenn Kraniske 
4 months ago
Greetings All,
So I have a database where I'm tracking inventory of Fishing Poles.  Not having any issues but I'm like to take it a step further.  I have a conbo box (pull down box) that only has selectable options of YES or NO.  Here's what I want to happen, if the user clicks the NO option, nothing happens.  However if the user selects the YES option, I'd like another field to appear where a receipt number can be added.  Is there a way to do this?  I've been all over YouTube and I'm coming up dry.  Thanks so much in advance.

-Glenn
Adam Schwanz
4 months ago
Just make an AfterUpdate on the combo box with an if statement, if its yes make the text box visible, otherwise make the textbox not visible.
Richard Rost
4 months ago
I do something almost exactly like this in Access Developer 1. If you check a box that says "shipping address same as billing" then it copies over the address info to the other fields. You'd do the same thing, just change the .Visible property of the boxes you want to show/hide.
Glenn Kraniske
4 months ago
So I did what Adam said but I found an issue.  What's happening is if I click the YES option, the appropriate field appears.  But when I move to the next record the field is still visible even though the NO option is chosen.  Here's my code;

Private Sub FishingPoleSold_AfterUpdate()
    If Me.FishingPoleSold = "1" Then
    Me.SoldTo.Visible = True
    Else
    Me.SoldTo.Visible = False
End If
End Sub
Kevin Robertson
4 months ago
You will also need to use the OnCurrent Event
Glenn Kraniske
4 months ago
OnCurrentEvent?  Where do I put the code and am I using the same code?
Adam Schwanz
4 months ago
Go to the form properties, on current event. And yes you can use the same code.
Adam Schwanz
4 months ago

Richard Rost
4 months ago
Watch the video Kevin suggested
Glenn Kraniske
4 months ago
Got it!  Works great, thanks.  By the way, that video was exactly what I needed.
Richard Rost
4 months ago
If you liked that, consider the rest of the Developer series. You'd be surprised how many cool things you can do with Access once you know how. :)

This thread is now closed. If you wish to comment, start a NEW discussion, below.
 


Back to Access Forum Comments
 

Start a NEW Conversation
 
Only students may post right now. Click here for more information on how you can set up an account. If you are a student, please LOG ON first.
 
Subscribe
 

You may want to read these articles from the 599CD News:

5/31/2022List Items Set Value
5/28/2022Access Bug Alert #Deleted
5/27/2022Add Anything
5/26/2022List Items Edit Form
5/25/2022Column Colors
5/24/2022Multi-Table Forms
5/23/2022Variables
5/21/2022Access Developer 39
5/21/2022Access Developer 39 Lessons
5/21/2022Access Developer 39
 

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
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
Email Richard
Mailing Address
Phone Number
Fax Number
Course Survey
Blog RSS Feed    Twitter

YouTube Channel    LinkedIn