Newbie to Macro need help

cubbyamber

Registered User.
Local time
Today, 01:15
Joined
Aug 28, 2006
Messages
60
Hi everyone,

I am a newbie to the more advanced stuff in creating a database in Access so I would really like some input. So I have a few questions.

Question 1: I would like to create a macro or some code so that you can import data from spreadsheets with different file names with a click of a button or in the least amount of steps possible. I did create a macro for importing a spreadsheet but I was wondering if there is a way where you click on a macro button it brings up a window so you can choose which file you want to import and then it imports it for you.

Question 2: I need a macro or code to pull numerous reports weekly and monthly automatically or with a click of a button

Question 3: Need a macro or code to pull numerous reports on Command.

Thanks in advance

Tracy
 
HERE Is a link and example you can use for Question 1:
Question 2 & 3:
Create macro/s to run the reports (OPENREPORT), then attach that macro in the click event of the button.
 
Okay, I looked at the link you sent me about my first question I will have to take a look at the code and see if I can figure it out.

As for my second and third question: I did the open report macro and it worked fine I have to figure out the click event thing though.

This is what I need, my client is a Private Investigator and he needs to be able to pull reports on the people that were found for the week and for the month. So I guess my question is, how do I make it so it only pulls up reports for specific weeks or months?

Tracy
 
Multiple ways to do this. Simpliest is to have a form that asks for the date or date range, and reference that in the query/ies that the report/s are based on. So basically in the criteria section of the query you would have (replace generic values with your actual names) FORMS!YourFormName!YourFieldName So if you were looking for a single date in your table to be within a date range, the criteria would be something like this:
BETWEEN FORMS!YourFormName!YourStartDate AND FORMS!YourFormName!YourEndDate
As an example
 
Okay, I understand the Queries thing but is there a way to make it so you can just enter a date without messing with the code?

Tracy
 

Users who are viewing this thread

Back
Top Bottom