dominicdunmow
Technical User
I have a table with a filed named "LC". All records have 1 of 4 values for "LC": - for example "Bob", "bill", "ben" or "baz".
I query this table using a value returned from a combo box in a form. The values in the combo box are "Bob", "bill", "ben" or "baz".
To query all records with Baz in LC field, I select Baz from the dropdown and click the command buttin and the query returns the appropriate dataset.
But I can't figure out how what to input in the QBE criteria to return all records.
Currently I use this line to return individual recordsets:-
IIf(([forms]![Services_Opportunity_Pipeline_Report_Menu]![LC Report]="Baz" Or ([Main Report].[Lead_LC]) Like "Bill" Or ([Main Report].[Lead_LC]) Like "Ben" Or ([Main Report].[Lead_LC]) Like "Bob"),[forms]![Services_Opportunity_Pipeline_Report_Menu]![LC Report],"")
Logic would tell me to add a wildcard to the negative side of the IIF statement but this doesn't work. Can anybody help please?