subreport display variable depending on records

  • Thread starter Thread starter Stephanie Stowe
  • Start date Start date
S

Stephanie Stowe

I have a report with 2 subreports in it. Some of the records which make up
the data source for the report have records to populate the subreports, some
do not. Is it possible to not display the subreport for a given master
record if there are no records within it? Take this example.

I have 2 tables, family and phone. A family may have 0 to many phone
numbers. My report data source is a selection from family. Then I have a sub
report for phone numbers. For the family Jones, I want the subpreport to
print the 3 phone numbers I have for them. For the family Smith, I do not
want the subreport to show/print at all because they have no phone numbers.

Is this possible?

Thanks
S
 
Stephanie said:
I have a report with 2 subreports in it. Some of the records which make up
the data source for the report have records to populate the subreports, some
do not. Is it possible to not display the subreport for a given master
record if there are no records within it? Take this example.

I have 2 tables, family and phone. A family may have 0 to many phone
numbers. My report data source is a selection from family. Then I have a sub
report for phone numbers. For the family Jones, I want the subpreport to
print the 3 phone numbers I have for them. For the family Smith, I do not
want the subreport to show/print at all because they have no phone numbers.


Try setting both the subreport control's and its section's
CanShrink property to Yes.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top