I have a Form that I'm entering search parameters on and then clicking search. My logic for the "search" button is checking if each field is null and if it is not appending those parameters to a query string.
Then one the query string is complete I'm using DoCmd.OpenForm to open a new form that displays the filtered results.
So far I have gotten text fields with dates and checkboxes to work from the search parameters page. I'm now trying to add a textfield to the parameters page and I'm running into trouble. When I enter something in and hit search it pops up "Enter Parameter Value" and then below that says whatever was entered into the textfield. If I then re-enter my search criteria the search works properly. How do I avoid this "Enter Parameter Value" step?
In the above code the strIncidentNumber is my Column in the database that I'm trying to match.Code:If Not IsNull(Me.txtIncidentNumber) Then strQuery = strIncidentNumber & " = " & Me.txtIncidentNumber End If
Thanks for any help.