I'm trying to create a button in a form that can change a query. I have to change the year that it gets the information from (to find out how much was made for a certain year- whether we need to go back in time or forward in time from where the query starts). I'd most likely need to be able to tell the user of the DB what year the query was currently on, also... so that they know whether or not to add/subtract a year to get information from the year they need. So that would have to be updated every time one of the buttons changed the year in the query.
Here is the SQL for my query:
SELECT projects.[Project Name], projects.[Client Name], projects.[Service Type], projects.[Date Completed], projects.[Final Payment]
WHERE (((projects.[Date Completed]) Between #1/1/2004# And #12/31/2004#));
As you can see, I need possibly a Macro button that could change the year from 2004 to 2005 when I want to add a year (and add a year every time the button was clicked), and another Macro button that could change the year from 2004 to 2003 (and subtract a year every time the button was clicked).
I'm stressed out because this has to be done in Access and I have to have it done by tonight, so anyone who helps- it is much appreciated. You'd be a life saver.
By the way- I'm using Access 2003