I am trying to use a selection from a combo box to generate a report where records match selection from combo box. Variable is used in combo box recordsource (to run report on AfterUpdate event) but not working as planned.
Datasource for combo box is ...
SELECT [qry_LKUPunitClients].[RegNo], [qry_LKUPunitClients].[CliLName], [qry_LKUPunitClients].[CliFName], [qry_LKUPunitClients].[LivingArea] FROM [qry_LKUPunitClients] WHERE '["& Me!txtVar!value &"]' ORDER BY [qry_LKUPunitClients].[CliLName], [qry_LKUPunitClients].[CliFName]
... the "Me!txtVar!value " code is used because I could not determine a way to use the variable directly (is it possible to do so?). Although "Me!txtVar!value " seems to produce the desired result ([Unit]="2" , i.e., all clients from Unit 2) the combo box lists clients from ALL units, not just Unit 2.
... what am I missing, and can I just use variable in this code instead of "Me!txtVar!value " ?



