Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
2 reports as one
Message
General information
Forum:
Visual FoxPro
Category:
Reports & Report designer
Miscellaneous
Thread ID:
00685654
Message ID:
00685781
Views:
36
This message has been marked as a message which has helped to the initial question of the thread.
>I have basically two different tables that I want to put on the same report. Is there a way to create multiple detail bands with the report designer? I know I could combine the two tables into one and have a field to determin which table it was. I could then create a data group in the report but this will only allow me to one header band for the group. So, I want to have two seperate header and detail bands on the same report. How can I do that.
>
>Eric Stephani

Eric,

You're off the right start! Put all the data from both tables into one cursor, being sure to add a new field that determines which table the record was in. Create a Data Group that breaks on that new group. In the Group Header, add all the fields for your "first" band, setting the Print When logic to RECTYPE = '1'. Do the same with all the fields in the Detail band and the Group Footer band, being sure to set the Print When to "1" for each of the items.

Then do the same for all the fields you want in your "second" band. Add the objects and set the print When to RECTYPE = '2' for everything. It gets real ugly when you place all these fields on top of each other, but that's what you have to do.

To make it easier to design, I usually do everything for the first band .. then jump over and create a new dummy report and layout all the objects for the second band. Once I have everything all set, including the Print When, I just do a cut and paste and add the band 2 objects from the dummy report back to the original report.

Another thing you can do to make maintenance easier, is once you have all the band objects for #1 in place, highlight them all and select GROUP so they're all grouped together. Do the same with the band 2 objects. Then if you ever have to do maintenance, you can grab the entire set of objects and move them out of the way to a dummy report .. manipulate them .. and then put them back.

Cathy
Cathy Pountney, Microsoft Visual FoxPro MVP
Memorial Business Systems, Inc. (www.mbs-intl.com)

My Website: (www.frontier2000.com)
My Blog: (www.cathypountney.blogspot.com)
My Book: The Visual FoxPro Report Writer - Pushing it to the Limit and Beyond
Free MSDN Article: What's New in the VFP 9.0 Report Writer
Free MSDN Article: The VFP 9.0 Report Writer In Action
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform