Nov 22 2005, 11:14 AM
Hello, I have a form, that gets its data from a query (Q2) using a summary, which gets its data from another query (Q1).
To filter the data by start and end data, I go in Q1 and add some criteria in the field where date records are stored.
Is there anyway I could implement this in the form, so that you have two text boxes, one for start date, one for end date, you fill the boxes with the dates you want and it automatically filter the data?
Or is there any tutorial that could teach me how to do it?
Thank you very much,
Nov 22 2005, 11:21 AM
add the two textboxes and then reference the controls in the criteria of your query:
BETWEEN [Forms]![YourForm]![YourStartControl] AND [Forms]![YourForm]![YourEndControl]
The form has to be open and the controles filled for this to work when the query runs.
Nov 22 2005, 11:26 AM
Check out this link
for info on Query by Form.
Nov 22 2005, 11:43 AM
Thank you very much! It works fine.
Is there any way you enter the values using a user friendly drop down menu?
Nov 22 2005, 12:00 PM
Yes, you can create a combo box that lists the dates on the form.
Nov 22 2005, 02:25 PM
Glad I could assist.
Good luck on future projects!
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here