Solved

Export Sub Report to Excel

Posted on 2013-12-09
6
2,761 Views
Last Modified: 2014-01-10
Hi there,

I have a report with four sub-reports one field in each) and now have to re-create the report so that it will export to excel.

Try as I might, these sub reports keep moving to the next rows below - does anyone have advice on how to make this come out on one line only?

Thanks,
CS
0
Comment
Question by:rporter45
  • 3
  • 2
6 Comments
 
LVL 100

Expert Comment

by:mlmcc
ID: 39707587
Make all the data be in the main report.

Crystal export to Excel is designed to put the subreport on the next line since it has the potential to use many lines.  There is no way to get it to remain on the same line with the main report

mlmcc
0
 

Author Comment

by:rporter45
ID: 39708369
Hi there,

Thanks for the quick response.  The way the data comes out of the system, we have to use a sub report even for one line of data. (It's a nightmare I know!).  If I have even limited the line to one - does the above still apply.  It sounds sensible but just want to confirm.  

Thanks very much - have a good day!
CS
0
 
LVL 100

Accepted Solution

by:
mlmcc earned 250 total points
ID: 39708553
It doesn't matter how much or little the subreport shows.

One way that might work would be to have the subreport return all the information you want displayed to the main report in shared variables then do the actual display in the main report.

To do that you need to put the subreport in its own section above where you want to display the information.
Make sure the subreport doesn't show anything.
    Suppress all section when blank
    Format the subreport to suppress if no data/blank (in the FORMAT subreport screen last tab I believe)
    Format the main report section to suppress when blank

You can right click the section the subreport is in
CLick INSERT SECTION BELOW
Left click the section in the left margin and drag it up so it is now above the section the subreport is in
Move the subreport up to the new section

mlmcc
0
Announcing the Most Valuable Experts of 2016

MVEs are more concerned with the satisfaction of those they help than with the considerable points they can earn. They are the types of people you feel privileged to call colleagues. Join us in honoring this amazing group of Experts.

 
LVL 22

Expert Comment

by:Ido Millet
ID: 39714031
If you can't create a VIEW, SP, or Command to avoid the need for the subreport, another possibility is to use an SQL Expression (they can handle correlated query scenarios).
Alternatively, if you need to hit a different data source, there is at least one UFL that allows you to use Crystal formulas to run dynamic SQL expressions and return information from a data source even if it is not the same as the report.
0
 

Author Comment

by:rporter45
ID: 39726682
Sorry for the delay in responding - Unfortunately the bridge between Crystal and the software that uses it does not support the use of SQL expressions :(  I have a couple that are exporting perfectly but wow does it take a long time to play with.  I will be back later today hopefully with the final outcome!

thank you - Colleen
0
 

Author Closing Comment

by:rporter45
ID: 39770736
Hi there,

I was able to do so (although time consuming) with limiting output to one line, aligning the data exactly and exporting minimal information.  

Thank you -
Colleen
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

Crystal Reports: 5 Tests for Top Performance It is complete, your masterpiece report.  Not only does it meet your customer’s expectations, it blows them out the water, all they want is beautifully summarised and displayed in a myriad of ways. …
Hello everyone, Hope you find this as helpful as we did. We have on the company I work for an application built in Delphi V with Crystal Reports 8. We all know that Crystal & Delphi can be temperamental sometimes and the worst thing is, nearly…
Microsoft Active Directory, the widely used IT infrastructure, is known for its high risk of credential theft. The best way to test your Active Directory’s vulnerabilities to pass-the-ticket, pass-the-hash, privilege escalation, and malware attacks …
Nobody understands Phishing better than an anti-spam company. That’s why we are providing Phishing Awareness Training to our customers. According to a report by Verizon, only 3% of targeted users report malicious emails to management. With compan…

840 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