Report Design
 Crystal Reports Forum : Crystal Reports 9 through 2020 : Report Design
Message Icon Topic: "Can Grow" fields create extra rows in Excel expor Post Reply Post New Topic
Author Message
pmjewett
Newbie
Newbie


Joined: 28 Nov 2016
Online Status: Offline
Posts: 9
Quote pmjewett Replybullet Topic: "Can Grow" fields create extra rows in Excel expor
    Posted: 20 Mar 2019 at 8:06am
Hello,

The report I'm creating couldn't be simpler but I have a need to set some of my detail fields to "Can Grow" but as soon as I do this I get extra rows upon exporting to Excel (I need to use the Excel 97-2003 export option).

Rows that do not have output that produces a "wrap" in these "Can Grow" fields don't produce the 2nd line.

This report is meant to replace an old Cognos version that allows for the growth of the fields but does not produce the extra line in an Excel export.

Any advice on this would be greatly appreciated.

Thanks
IP IP Logged
kevlray
Admin Group
Admin Group
Avatar

Joined: 29 Oct 2009
Online Status: Offline
Posts: 1587
Quote kevlray Replybullet Posted: 20 Mar 2019 at 8:12am
Unfortunately when you export to Excel, if a text box (or field) is set to grow and it spans more than one line, then an extra row will be created (one of the fun things with exporting to Excel).  Only 'fix' to this that I know of is to make the text box (or field) wide enough so that it does not wrap.  The Cognos Excel export code apparently works different than the Crystal Report Excel export code.

If anyone else has a solution, I would like to know also.
IP IP Logged
pmjewett
Newbie
Newbie


Joined: 28 Nov 2016
Online Status: Offline
Posts: 9
Quote pmjewett Replybullet Posted: 20 Mar 2019 at 8:20am
Originally posted by kevlray

Unfortunately when you export to Excel, if a text box (or field) is set to grow and it spans more than one line, then an extra row will be created (one of the fun things with exporting to Excel).  Only 'fix' to this that I know of is to make the text box (or field) wide enough so that it does not wrap.  The Cognos Excel export code apparently works different than the Crystal Report Excel export code.
If anyone else has a solution, I would like to know also.


Thank you for the reply. I don't have the option to simply widen the field in this (rare) case as not only does the return data in these fields vary greatly, but I'm exporting the same report as a PDF as well (and the requirement here is for it to fit on 8.5 x 11).

The extra rows are an issue as they interfere with users efforts to use vlookup functions or to simply click on a column to get an accurate record count.

Edited by pmjewett - 20 Mar 2019 at 8:22am
IP IP Logged
hilfy
Admin Group
Admin Group
Avatar

Joined: 20 Nov 2006
Online Status: Offline
Posts: 3701
Quote hilfy Replybullet Posted: 20 Mar 2019 at 9:26am
The only way I've found around this is to not turn on Can Grow. From there, you don't have to expand the width of the field, it will export to Excel correctly. However, this won't work for your PDF export. You may need to have two versions of the report - one for PDF export and one for Excel export.

-Dell
IP IP Logged
pmjewett
Newbie
Newbie


Joined: 28 Nov 2016
Online Status: Offline
Posts: 9
Quote pmjewett Replybullet Posted: 20 Mar 2019 at 9:42am
Originally posted by hilfy

The only way I've found around this is to not turn on Can Grow. From there, you don't have to expand the width of the field, it will export to Excel correctly. However, this won't work for your PDF export. You may need to have two versions of the report - one for PDF export and one for Excel export.

-Dell


Yep, I was trying to avoid having different versions of the report to maintain. :)

Thank you though.

I didn't hold out much hope there would be an alternative solution but worth a try. Thanks again
IP IP Logged
Post Reply Post New Topic
Printable version Printable version

Forum Jump
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum



This page was generated in 0.031 seconds.