Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

how to display subreport in one section of the mainreport?

Status
Not open for further replies.

calvi

Technical User
May 26, 2003
87
NL
How do I display subreport next to the mainreport in one section sothat it will show both in one line? I have some records (meetings) from the main report in one day. I group these meetings per day. I put my subreport (also another meetings) in the groupsection date, but this will show above the detail section where i put my mainreport fields. If i place my subreport in the detail section then it will show (same meetings) repeatedly per record.<-- this is what i don't want. How do I solve this: that my subreport will be in one line as my mainreport?

this is what it should look like
e.g: in one day:

------ mainreport ------- --------- subreport ----------
LOCATION GROUP EMPLOYEE NOTES

room 2 IBM Mark, John Salesman
room 3 NOVELL Todd Technician
room 4 HP Martin Support
 
Just place the subreport where you want it to display. If the data was structured in a manner where you didn't need a subreport, you would just grab the database field and place it where you wanted it. Same with a subreport, its just another object, you can place it anywhere you like.

Software Sales, Training, Implementation and Support for Exact Macola, eSynergy, and Crystal Reports
 
my mainreport data is in the detailsection now, if I place my subreport to the right beside the detail of the mailreport, then subreport will show repeatedly.

e.g:
---- main report ----- --------- subreport -----------
LOCATION GROUP EMPLOYEE NOTES

room 2 IBM MARK, John Salesman
TOdd Technician
Martin Support

room 3 NOVELL Mark, John Salesman
Todd Technician
Martin Support

room 4 HP Mark, John Salesman
Todd Technician
Martin Support

I would like only once displayed the subreport. how do i do that?
 
You need to pass something from the main report that identifies which employee belongs there. [Subreport Links] can be found under [Edit] on the menu. Pass the value, and then use it in record select in the subreport.

Without knowing your database, I have no idea of what specifically you need to pass.

Madawc Williams
East Anglia, Great Britain
 
right this is the situation:

-------main report------ ------ subreport----------
DATE ROOM BEGTIME ENDTIME JOBTIME ENDTIME EMPLOYEE NOTE
1-2 RM1 9:30 - 20:00 8:00 - 13:00 Mark sales
RM2 15:00 - 22:00 13:00- 17:00 Todd support
RM3 10:00 - 17:00

2-2 RM4 9:00 - 20:00 8:00 - 13:00 Dennis

Because BEGTIME and ENDTIME are the same field as JOBTIME and ENDTIME i made a subreport for jobtime, endtime, employee and note.

It should be like the above sample, but now per record the subreport repeats.
e.g.:
------ main report---- ---------sub report -------
1-2 RM1 9:30 - 20:00 8:00 - 13:00 Mark sales
13:00 - 17:00 Todd support
RM2 15:00- 22:00 8:00 - 13:00 Mark sales
13:00 - 17:00 Todd support
So I made a group in the main report by date, sothat subreport only once displayed, and put subreport in the group section, but this is above the detail section so it does not displayed on 1 line.
From the main report I pass by Date. What do you mean by record select in the subreport?
 
Subreports have record selection, just like main reports. They can use something passed by the main report.

If you had a customer and customer transaactions, you could pass the customer number and then have the subreport show transactions just for that customer.

Madawc Williams
East Anglia, Great Britain
 
Well, I found and solved this by grouping the main report by date and put the subreport in the group section and click the property: underlay the follwing sections. It works.
Thx madawc, for your comments for the record selection.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top