Wednesday, September 02, 2015
Text Size

Crystal Reports: Exporting to Excel omits column headers

If you've been to the point where you're exporting a report to Excel, and only some of the column headers appear, then try this:

I googled this for ages and found different suggestions here and there but none of them produced consistent results.  One solution was to untick "Simplify page headers" on the Excel Format Options when you export the report.  Because our report is exported via a web-based system, this extra dialog doesn't appear when our users export their reports.  Not that it solved it as only some different headers appeared on the exported report when we followed that suggestion.

Consider the following report in design view, only the circled headings would appear on the exported report:

The solution I found that worked for me, was to make all the heading boxes the same height and to get rid of all the unnecessary extra gridlines (the ones that appear in the ruler as little arrows).

  1. So right-click on a heading text box that works

  2. Select "Size and Position..."
  3. Copy to clipboard the exact height value
  4. Right-click on a faulty heading textbox
  5. Select "Size and Position..."
  6. Paste the same height value as the one that worked
  7. Repeat for all heading textboxes that weren't appearing

This will yield something like the following:

A few other things that I did to this report that may have contributed to it working:

  1. Checked all headings text boxes are aligned to one gridline and they're the same height.
  2. Checked all data field text boxes are aligned and the same width as their respective column heading.
  3. Remove any ruler gridlines that don't truly serve a process (even if they're just for margin purposes)


# hilfy Fri, 4th June 2010
My general rule of thumb when creating a report that I know is going to be exported to Excel is to align the left sides of the data and the column label and then to make them both the same size. I do this by clicking on the data field, then shift-click on the column label and use the right-click menu that has options for align and size.
Like | Dislike | +2 Reply | Reply with quote | Quote
# CJA Tue, 20th July 2010
To my surprise that worked. I sized the Text field headings to match the size of the column field headings and the report, headings and all exported perfect. Thank you.
Like | Dislike | +2 Reply | Reply with quote | Quote
# Renee Mon, 10th September 2012
Thank you! That worked perfectly. I too had been googling for ages to find an answer and this is the first one that has worked. Thank you so much. :-)
Like | Dislike | +1 Reply | Reply with quote | Quote
# MRGMSR Thu, 23rd October 2014
This totally worked for me! Super easy! Thanks for sharing.
Like | Dislike | 0 Reply | Reply with quote | Quote
Add Comment





Help Develop!

Thank You! :c)

Connect: Google+

Visitors of the World

Latest Posts