Solved

After update for combo box

Posted on 2014-03-26
2
686 Views
Last Modified: 2014-03-31
I have a combo box that is based on the value entered in the field above it. It is only working if I hit Shift F9 to update it.

Is there a way to do an "After Update" event that will update the combo query after a value is entered. That way the combo underneath it has the right choices without hitting Shift F9.

Thanks!
0
Comment
Question by:cansevin
2 Comments
 
LVL 34

Accepted Solution

by:
PatHartman earned 500 total points
ID: 39957327
If the combo is using a query with criteria as a rowsource and the criteria points to a control on the form, you need code to force the query to run in the AfterUpdate event of the field used as criteria.

Me.cboCity.Requery
0
 
LVL 84
ID: 39957329
You could requery the second combo form the AfterUpdate event of the first:

Sub FirstCombo_AfterUpdate()
  Me.SecondCombo.Requery
End Sub
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

When you are entering numbers in a speadsheet, and don't remember what 6×7 is, you just type “=6*7" instead. It works in every cell! This is not so in Access. To enter the elusive 42 in a text box, you have to find a calculator, and then copy the re…
Regardless of which version on MS Access you are using, one of the harder data-entry forms to create is one where most data from previous entries needs to be appended to new records, especially when there are numerous fields and records involved.  W…
Using Microsoft Access, learn some simple rules for how to construct tables in a relational database. Split up all multi-value fields into single values: Split up fields that belong to other things into separate tables: Make sure that all record…
What’s inside an Access Desktop Database. Will look at the basic interface, Navigation Pane (Database Container), Tables, Queries, Forms, Report, Macro’s, and VBA code.

912 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

27 Experts available now in Live!

Get 1:1 Help Now