473,408 Members | 1,707 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,408 software developers and data experts.

Requery Combo Box Automatically From A Query

Hi I have a table called tblBooking. One of the fields in the table is the return date of the van. I have created a query that's called qryAvailableVans. Within this I have the fields VanID, registration and return date. For the return date their is the criteria <Date() and ive unchecked the show box. This means that all the vans that have been returned before todays date show in the query. I then have a form called frmBooking. Within this, there is a combo box with the row source qryAvailableVans. This therefore only shows the details of the vans that are available to book. Is there any way to automatically refresh the combo box options because I have to close the form and then reopen it if I change a return date in the booking table or process a new booking.
Feb 25 '16 #1
1 1512
Seth Schrock
2,965 Expert 2GB
What I would do would be to put the following code in the control that you would edit just before your van combobox After_Update event:
Expand|Select|Wrap|Line Numbers
  1. Me.ComboBox_Name.Requery
This is update the list just a second before you use it.
Feb 25 '16 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

5
by: will eichert | last post by:
Greetings. I have a problem with a combo box incorrectly displaying blank items when returning to a form from a modal form. It's fine when the main form first comes up, but gets messed up when the...
1
by: Robert Neville | last post by:
The solution to my dilemma seems straight-forward, yet my mind has not been forthcoming with a direct route. My Project form has a tab control with multiple sub-forms; these distinct sub-forms...
1
by: Me | last post by:
Hi, In my application, I have two records, customers and transactions.Each customer may have many transactions and so I have created a one to many relationship between them. I have a form...
2
by: Steve | last post by:
Access 97. I have a form where there is an option group with two buttons, and a combo box. The combo box Row Source is a query. The option group has two options a) include a subset of the...
5
by: Giloosh | last post by:
Hello, I have a combobox with a rowsource of two fields. and even though the combobox only shows the name, when i pull down the name i grab the id that it belongs to like this: 'AFTERUPDATE:...
0
by: Budinski | last post by:
I have a subform that has a datasheet in it. In the datasheet I have multiple records. Each record has many textboxes and combo boxes. I have a particular combobox with 2 columns, Column 1 has the...
2
by: hlebforprimeminister | last post by:
Hi I am having a problem with the visualbasic for requerys in access. I have had a look at some of the other discussions but i can't find an answer. So, my problem is this. I have a form...
20
by: exipnakias | last post by:
Hello Guys. In a form I created a listbox which looks up the values of a table. I want: 1) ..to create a query where a parameter will be needed in order to be loaded. But I do not want to...
1
by: didihynes | last post by:
Hi Guys, I'm in desparate need of help. I am producing a database for my dissertation and have got majorly stuck. I am currently creating a form in which the user will select a student from a...
5
by: Haagimus | last post by:
I am trying to create an access form that will have multiple combo box drop downs. There are two that will need to be linked in the form. The selection of the first will need to become the query...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.