Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Using a query within a form to search for specific data

Status
Not open for further replies.

tbiceps

IS-IT--Management
Nov 23, 2005
106
US
I created a form that queries a table for specified information based on 3 search criteria questions from a drop down list. If information is found based on my search criteria, then a resultant list will appear. If I change my search criteria, and it doesn't find any results then I should return a blank list, however, the previous search results remains on my screen. I would like by form to operate as follows: When I attempt a search for data based on my search criteria and there is no matching data is found, then I would like to replace the previous list, with a blank page stating "No matching Data," instead of returning the list found from the previous search. Does anyone have any clues on my problem?
 
can you post the code that you are using for the search

-Pete
 
When you say post the code, what exactly are you referring to? I built this particular form using the wizard. I have a list box that has the following search query listed in Row Source: SELECT Query4.[Report ID], Query4.[Standard or Customer Specific], Query4.[Report Title] FROM Query4;

Query 4 filters the column information.
 
Try Requerying the second list. I'm assuming that you have more than one list box on the form. One the first list boxes, OnClick event, add 'Me.List2.requery'

"The most overlooked advantage of owning a computer is that if they foul up there's no law against whacking them around a bit."
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top