G
Guest
I have tried creating a form where the user enters an id number in Control A
and a second control B displays the name associated with the value in Control
A. A combi box to lookup the number is not acceptable - the user has to type
in the number.
The id is held in table C and the name in table D. If I create a query
MyQuery with Control A as the criterion it returns the correct name when I
run it but if I paste the SQL into the ControlSource of Control B it does not
update.
I have tried adding a requery or refresh statement to the OnUpdate event of
Control A but it doesn't work. I've also tried creating a form with MyQuery
as the RecordSource and then creating a control based on the site name field
but still no luck.
The only way I can get it to work is to put the statement
=Dmax("[Site_Name]","MyQuery") in the ControlSource of Control B and to add a
Requery statement to the OnUpdate event of Control A.
It all seems terribly complicated to achieve something apparently so simple.
Any ideas?
and a second control B displays the name associated with the value in Control
A. A combi box to lookup the number is not acceptable - the user has to type
in the number.
The id is held in table C and the name in table D. If I create a query
MyQuery with Control A as the criterion it returns the correct name when I
run it but if I paste the SQL into the ControlSource of Control B it does not
update.
I have tried adding a requery or refresh statement to the OnUpdate event of
Control A but it doesn't work. I've also tried creating a form with MyQuery
as the RecordSource and then creating a control based on the site name field
but still no luck.
The only way I can get it to work is to put the statement
=Dmax("[Site_Name]","MyQuery") in the ControlSource of Control B and to add a
Requery statement to the OnUpdate event of Control A.
It all seems terribly complicated to achieve something apparently so simple.
Any ideas?