Refreshing LOV's

smjohns

Registered User.
Local time
Today, 14:47
Joined
Mar 15, 2004
Messages
20
Hi,

I have set up a new record creation form and I have set up three of the fields as combo-boxes which are restricted by data entered in a field earlier on the screen. This works quite well unless the user changes the data in this earlier field. If this happens, the LOV's are not refreshed and the contents are still based on the original value.

Is there a way of refreshing the LOV's everytime the initial value is changed? I cannot use me.refresh/requery as this is a new record creation and all the mandatory fields will not be have been completed by this stage. This is the query which is similar for all the LOV's

SELECT [Accommodation].[Accom_ID] FROM Accommodation WHERE [Accommodation].[Zone_ID]=DLookup("[Zone_ID]","Transport_Company","[Transport_ID] = '" & [forms]![reservations_modify_rh]![Transport_ID] & "'");

[forms]![reservations_modify_rh]![Transport_ID] = the earlier field that is used in the select statement.

Hope someone can help.

Kind Regards

Simon
 
You need to requery the combos, not the form.

Me.Combo1.Requery
Me.Combo2.Requery
Me.Combo3.Requery
 
Hi Pat,

Thanks for you help, that works perfectly. Cheers.

Simon
 

Users who are viewing this thread

Back
Top Bottom