Multiple record set format on same report

Posted on 2008-10-12
Last Modified: 2013-11-28
I need to create a report to print a manufacturing work order production steps traveler (for those familiar with manufacturing this is basically the production routing/bill of materials traveler). This is a hard copy document that describes every necessary production steps for a making a part/product. Currently we are generating and printing this hard coded report from an Excel workbook and we have more that 40 different versions. The report is of a tabular layout with every line/column boxed. We want to replace theses Excel worksheets with an MS-Access report. The work order information and production steps are all contained in SQL Server tables and I have the capability of adding any extra columns if necessary. What I was planning to do was to design a report for a work order and a sub-report for the work order steps. My issue is that I have up to 5 different record/line/step formats, all of the same total line width by with different number of columns, font sizes and heights. I do not want to code 40 different reports. Is there a way I can define 5 different record/line/step format and conditionally hide/display based on a values found in the work order steps record set?
Question by:fishbait01
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
  • 2
LVL 38

Assisted Solution

puppydogbuddy earned 100 total points
ID: 22697547
There are quite a few things you can do, and most of it can be done using VBA code, as illustrated in the link I provided below.  Each report section is really just a control whose properties you can modify.  For example, see the code used to hide the detail section to print out a Summary Report.  The ability to exclude/collapse or include/expand, or otherwise control certain sections of a report/subreport  depending on user selection is an extremely powerful tool that I think you will find extremely useful for the things you want to accomplish.
                                       Access Report Tricks
LVL 74

Expert Comment

by:Jeffrey Coachman
ID: 22698973

Obviously, there is absolutely no way any expert here can give you a concise answer without seeing your data.

You stated what you have, but it is not clear exactly what you need.
Meaning, you simply stated:
   "We want to replace theses Excel worksheets with an MS-Access report."
So how can we help, if we have no idea of how these Excel reports are designed?

Or am I missing something?


Author Comment

ID: 22700805
Theses excel worksheet have no macros. They simply are static columns to which a user manually enters data in 4 cells then prints. In the attached XLS file example, data is manually entered in cells A2, D2, D3 and E3. Then the document is printed.

What I want to do is replicate this document using a MS-Access report. As I mentionned before the work order and work order step data are already in a SQL Server database except for the info column. I plan to add this data to the appropriate SQL Server tables. Imagining a group sort on the work order number, the excel lines would breakdown as follows:
     Lines 1,2,3,4 are work order group header information
     Lines 5 through 18 are work order steps information (the line count will vary based on the part)
     Lines 19 to 22 are static group footer information.

I planning to have a report to manage the work order group header and static footer and call a sub-report to handle the work order steps. Because I have, in this example, 4 different work order steps layout (Lines 5,9,14 and line 16) I am wondering if I could have 4 different "report detail sections", one for each layout type, and selectively choose which one to display based on data found the record set returned by the data source?
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

LVL 74

Expert Comment

by:Jeffrey Coachman
ID: 22701251

What you are trying to do here will require Excel coding as well.

Your question is more of a "Design Project", than a simple question requiring a straightforward answer.

Click the "Request Attention" button in your original post, and ask that the Excel Zone be added to this question.


Author Comment

ID: 22701605

I thank you for taking the time to respond but I feel that we are not on the same wave length here. Puppydogbuddys reply was helpful but did not totally guide me to what I am looking for. I'm asking an MS-Access report question about the possibility of having multiple detail sections in a same report. Maybe it is not possible and if that is the case, then case close and I will look for another reporting tool. I am not an MS-Access developer so I might not be using the right terminology. Maybe I made the mistake of giving out too much information. We are hoping to replace this current business process described earlier and dropping Excel altogether.
LVL 38

Expert Comment

ID: 22701705
You can't create 4 detail sections simultaneously, but you can, for example, dynamically change the record source , which will accomplish the same thing because the detail section can grow and shrink with the amount of detail.  The Access report writer is very robust and flexible.

Example Of one way out many different ways.
If Me!RptNo = 1 then    <<<<<RptId passed from report launcher
    Me.RecordSource = strSql1
ElseIf Me!RptNo = 2 then
    Me.RecordSource = strSql2
End If

Accepted Solution

fishbait01 earned 0 total points
ID: 22709746
Thanks for all your help. We have decided to use a different solution and we will not be using neither Excel or MS-Access.

Featured Post

Instantly Create Instructional Tutorials

Contextual Guidance at the moment of need helps your employees adopt to new software or processes instantly. Boost knowledge retention and employee engagement step-by-step with one easy solution.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

A simple tool to export all objects of two Access files as text and compare it with Meld, a free diff tool.
Access developers frequently have requirements to interact with Excel (import from or output to) in their applications.  You might be able to accomplish this with the TransferSpreadsheet and OutputTo methods, but in this series of articles I will di…
In Microsoft Access, learn how to “cascade” or have the displayed data of one combo control depend upon what’s entered in another. Base the dependent combo on a query for its row source: Add a reference to the first combo on the form as criteria i…
With Microsoft Access, learn how to specify relationships between tables and set various options on the relationship. Add the tables: Create the relationship: Decide if you’re going to set referential integrity: Decide if you want cascade upda…

717 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question