The problem is the query doesn't exist... its a string generated on a form and the SQL is in the listbox (Search Seminar- lesson 23)
Reply from Alex Hedley:
I've just taken a look at the Search Seminar sample db, it's been a while since I've watched it so had to fresh my memory.
If you look at the CustomersFromStateQ you could match that, so have a checkbox on your Form that says Blanks then add this criteria to your Query:
Like IIf([Forms]![MainMenuF]![ExactState],[Forms]![MainMenuF]![State],"*" & [Forms]![MainMenuF]![State] & "*") Or IIf([Forms]![MainMenuF]![BlankState],"") Replacing names with your Form and Field Names,
If you have a SQL String instead of a Query use the principles from CustomerListSQLF Again with a checkbox for show Blanks
If BlankFirstName = True Then If Wh <> "" Then Wh = Wh & " " & AndOrCombo & " " Wh = Wh & "IsNull(FirstName)"
Sorry, only students may add comments.
Click here for more
information on how you can set up an account.
If you are a Visitor, go ahead and post your reply as a
new comment, and we'll move it here for you
once it's approved. Be sure to use the same name and email address.
This thread is now CLOSED. If you wish to comment, start a NEW discussion in
Access Search Seminar.