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

Cross-tab exporting to Excel

Status
Not open for further replies.

RenaG

Programmer
May 3, 2011
132
US
I have a cross tab that works perfectly and looks correct in Crystal. The format looks like this:
Code:
|              Column #1 Name          Total
[b]Total[/b]          Count of @Order_Type   Count of @order_type 
Row #1 Name    Count of @Order_Type   Count of @order_type
Row #2 Name    Count of @Order_Type   Count of @Order_type

When I export it to Excel, the first Total is in a column by itself, then the Row#1 Name is on the next line, next column over and takes 2 columns. Then I have two blank columns. Then everything looks good until I get to the end - the last 3 entries each take 2 columns (all the others took only 1). I hope that makes sense. I am just wondering why I have these extra columns and if there is anything I can do to force to format better. I have played around with page size, the fields in the Page headers lining up correctly; just about anything you would normally do to get a Crystal report to export to Excel cleanly but it hasn't helped.

TIA!
~RLG
 
Sorry - I am working in Crystal 2011.

~RLG
 
How is the data in the report or page header set up? If you don't include the header information, does the report export correctly? What happens if you export to Excel (Data Only)?

When you export to Excel, you have some options for how to set the column size - make sure that you select the section type that the crosstab is located in.

-Dell

DecisionFirst Technologies - Seven-time SAP BusinessObjects Solution Partner of the Year
 
Hi Dell,

Thank you for the helpful tips.

I did try to suppress the report header and the results were still the same (sans Report Header). The cross-tab is in the Report Footer but it didn't make any difference if I told the export to base the columns on the Report Footer or took the default.

I played around with the data only option and got a pretty good export. When I showed the user the results from both options (regular export and data only), she said that she liked the look of the regular one and was ok with having to do a little clean up.

Thanks again!

~RLG
 
I was going to suggest "data only" export too. If it is not good enough you may also consider using a "pivot table" like report. Check the first 2 minutes of this video: - it compares the same data presented as a crystal reports cross table , SSRS matrix and SQL Pivot table.
If this is a solution you can request a free license for the tool from this link:



Viewer and Scheduler for Crystal reports, SSRS and Dynamic Dashboards.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top