frank_guess
asked on
Using a table to run a query from and writing each item into a report.
I have a table with Department Numbers and names and need to create reports for each of the department numbers from the table. The reports are created from a personnel table and it would be by department number. I am working to automate the report creation versus someone having to select 200 separate department numbers.
Table one - TBL_Dept_List - DeptNo, DeptName, TotalTeam
Report has data in it along with the team member information with the DeptNo as the link.
Could use a little help Thank you.
Table one - TBL_Dept_List - DeptNo, DeptName, TotalTeam
Report has data in it along with the team member information with the DeptNo as the link.
Could use a little help Thank you.
Hope below link give you the solution on how to accomplish this;
http://office.microsoft.co m/en-us/ac cess-help/ set-the-op tion-to-pr int-each-r ecord-grou p-or-secti on-on-a-se parate-pag e-HP005187 374.aspx
HTH,
Daniel
http://office.microsoft.co
HTH,
Daniel
ASKER
Thank you
The problem is I have the table already finished but I am looking for the module or code behind the button to make this happen.
The problem is I have the table already finished but I am looking for the module or code behind the button to make this happen.
Did you try to create a Report based on a Group/ Section of your DepartmentName / No?
Then follow the steps as suggested in my link.
HTH,
Daniel
Then follow the steps as suggested in my link.
HTH,
Daniel
If I am reading you request correctly there is no need to create multiple reports from data in the same table.
Simply create one report with all the data, then simply filter it for the data (department, team member, ...etc) you wish to display.
I believe this is basically what danishani is suggesting, so I'll step aside and let him outline the principles...
;-)
JeffCoachman
Simply create one report with all the data, then simply filter it for the data (department, team member, ...etc) you wish to display.
I believe this is basically what danishani is suggesting, so I'll step aside and let him outline the principles...
;-)
JeffCoachman
ASKER
Sorry I guess I was not clear. I have a table with the business cost centers, I need to run a report for each cost center number and save the report as a file with that name example:
Cost_Center_680_5040_05_12 _2011_Pers onnelRpt.r tf
Cost_Center_680_5022_05_12 _2011_Pers onnelRpt.r tf
Cost_Center_680_5075_05_12 _2011_Pers onnelRpt.r tf
These reports go on through over 200 or more business centers. The table is a list of those cost centers and the reports are created by matching the cost center number against the Cost center number that is listed in the data file that is used to create the report. Even through the report can be page separated by start the report by the cost center number this does not allow you to create individual reports. Why am I needing this is to create a folder or directory of individual cost center reports without having to manually run each one and save it myself. Takes all day that way versus using the table and creating each report without human touch.
Cost_Center_680_5040_05_12
Cost_Center_680_5022_05_12
Cost_Center_680_5075_05_12
These reports go on through over 200 or more business centers. The table is a list of those cost centers and the reports are created by matching the cost center number against the Cost center number that is listed in the data file that is used to create the report. Even through the report can be page separated by start the report by the cost center number this does not allow you to create individual reports. Why am I needing this is to create a folder or directory of individual cost center reports without having to manually run each one and save it myself. Takes all day that way versus using the table and creating each report without human touch.
Ok, below link give you an idea on how to do this:
http://bytes.com/topic/acc ess/answer s/799273-a ccess-2007 -create-re port-per-g roup
Just copy the idea and replace the code to your convenience.
HTH,
Daniel
http://bytes.com/topic/acc
Just copy the idea and replace the code to your convenience.
HTH,
Daniel
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
I will review and get back to you. Thanks
ASKER
That is exactly what I am looking for. Thanks
;-)
You can create a table of all departments and use an additional field to select departments on which to report and do VBA module to read the table and create a report for each table value.
Both of the above would generate a different report for each department or
You can create a table as above and use it in a query to create your reports in one file.