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 SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Crystal 10 and subreports

Status
Not open for further replies.

gbpcpd

Programmer
Jun 8, 2005
2
0
0
US
As new user to crystal I hoping to find a answer to a question regarding subreports and having to display them in the main report.

I have a main report in which the detail section are supressed and only the summary in group footer is displayed. The main report calls a subreport in which I use a shared variable to pass back a number. The subreport work fine and I have reduced the output of the subreport as small as I possible but I still get large blank spaces caused by the subreport executing many times. Is there a way to not display the section in the main report where the subreport executes or is this a limitation of crystal?

Thanks in advance!
 
Hi,
Where ( in what section) is the subreport located?



[profile]

To Paraphrase:"The Help you get is proportional to the Help you give.."
 
The subreport is in Detail section a and is the only thing in the section.

Thanks
 
It is a limitation, however subreports should be avoided, especially in a details section because it will fire for every row in the main report.

Consider adding a subquery either by using a SQL Expression or by creating an Add Command to paste in the entire SQL for the report.

-k
 
I suppose the main question for me is whether the subreport is required to execute on a row by row basis....?
 
I'm not sure if I am missing something here or not but all it seems you are trying to do is suppress a blank subreport. This can be done as follows:

On the base report right click on the subreport, select "Format Subreport...", the select the "Subreport" tab, check the "Suppress Blank Subreport" box, and the click the "OK". If your subreport is indeed blank that should do the trick.
 
Note: I made the assumption that since the subreport is simply returning a variable that it does not need to be visible. If that is the case all sections of the subreport can be suppressed resulting in a "blank" subreport that can be surpressed in the main report.
 
You should first make sure that you have all sections in the subreport suppressed and then make the subreport as small as possible (and remove borders from format option) and then pull the section borders up as far as possible. Now, if your report is in the details section then it should not cause a problem as it will take up very little space.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top