I have a rental database with start date and stop date. i would like to have a form for the user to enter the month and then click a button to run all starts for that month. how can i do this?
An update query is used to change values in tables, and it sounds to me like you just want to have a button in a form that launches a report that shows records pertinent to the current month.
I apologize if I misunderstand.
Use a query for the record source of the report. THe query should include these 2 calculated fields:
StartMonth:Month([StartDate]) which has the criteria set to Month(Now())
StartYear:Year([StartDate]) which has the criteria set to Year(Now())
Then put a button on your form that launches the report.
I just reread your original question and now I see you want the user to ENTER the month, not just use the current month. Sorry. Use a parmeter query as the record source of the report. The criteria for the start date field should be:
Month([StartDate])=[Choose a month from 1-12] And Year([StartDate])=[Choose a year]
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.