cancel
Showing results for 
Search instead for 
Did you mean: 

Crystal reports for Visual studio 2010 export to xls throws an error when having subreports

Former Member
0 Kudos

Hi,

I'm using Crystal Reports for Visual Studio 2010 (i have the latest version 13_0_4 )

I came up with a problem that i've never had before this update.

Reports that include subreports cannot be exported to xls format (excel 4.0 worksheet)

It throws a runtime C++ unhandled error and application is forced to close

( in function ExportToDisk )

Does anyone have any idea  ?

Accepted Solutions (1)

Accepted Solutions (1)

0 Kudos

Hi Nick,

What happens if you export from the Viewer?

Don

Former Member
0 Kudos

The same ..and from Visual studio 2010 when i try to export the preview to xls

It throws a C++ runtime exception and Visual studio closes.

0 Kudos

Hi Nick,

Can you attach the report with saved data so I can test? Use dummy data and/or filter it to just one or 2 pages.

Use the advanced editor button, zip the report up and then rename the zip file to *.txt and then you can attach it. 1 Meg limit.

You can try using DebugDiag from MS and capture the dump file on your app crash. Analyze it and it should tell you what CR dll it needs the PDB for. Let me know and I'll FTP it for you. It may give us more info also.

Thanks

Don

Former Member
0 Kudos

Hi Don,


Check this link below

http://www.2shared.com/document/4RxQzclM/rptVouchersReportzip.html

It contains the .rpt with saved data

The subreport is dynamically shown (when the parameter 'Serial' is set to true)

And the link below is the 'blue' screen inside Visual Studio , when i try to export the report preview to xls .

http://www.2shared.com/photo/mucHeT4q/ExportXLS.html

Thanks

0 Kudos

Works for me...

Can you paste in the code you are using?

Thanks again

Don

0 Kudos

Ah, you are doing this from the .NET IDE... try it through your app, that Report designer is the legacy Embedded Designer and it may be limited in what it can do. It' smore as a quick check tool is all.

You said you have Crystal Reports 2011, what happen when you run it in there and also what happens when you run your app and export from the Viewer?

Don

Former Member
0 Kudos

No , i dont have Crystal reports 2011 ( standalone version).

I use cr inside Visual studio 2010 for deploying win applications.

And in both cases (from the application that is deployed  and visual studio) it crashes.

Maybe its the embeded version of crystal reports that has this problem

0 Kudos

Hi Nick,

Just to clarify, you are exporting from the app and when viewing the report and then using the Export button in the viewer it crahses also?

Yes, xlxs is something new to CR for VS 2010, the embedded designer built into .NET IDE and is for simply testing purposes only.

It exports from my .NET IDE also...

So it would appear you may have some dependency or could be a permission issue. Close VS down and then rick on the short cut and select run as Adaministrator, see if that works? If it does it is a permission issue.

Is this a windows or WEB app?

Still waiting for you code snippet...

Don

Former Member
0 Kudos

Hi Don ,
Sorry for the delay

I send you a link with a minimal project

(build in framework 4 , crystal reports 13_0_4 )

There is a windows form with a crystalreportviewer and it loads (when you press the 'Show' button) a crystal report document.

If you try to export the report in xls format (not xlsx ! ) you will see that it crashes..

Remember to check 'SubReport'   chechbox in order to show the subreport..otherwise it works fine !

http://www.2shared.com/file/Eu1UTgmR/CRVS2010.html

Thanks...

former_member183750
Active Contributor
0 Kudos

So, you've got two threads and thus two of us working on the same issue...

http://scn.sap.com/thread/3210695

http://scn.sap.com/thread/3210737

1) This is against the rules of engagement on these SCN forums

2) By doing this, you are taking up time of two people, one of whom could be working on someone else's important issue - not sure how you'd justify this...

3) These are community forums, not free technical support for a free product. You may get an answer, you may not. The answers may be timely, they may not. If this is a critical issue, please create a phone case here:

http://store.businessobjects.com/store/bobjamer/en_US/pd/productID.98078100?resid=S6I@hgoHAkEAAGsiyV...

If you wish to continue, please choose which thread you want to work on and close the other one.

- Ludek

Former Member
0 Kudos

Hi ,

It seems to me it was not the same discussion board ..

Thats why i opened  two threads for my issue.

I dont want to waste two people's time , especially if you are working on the same team

Sorry.

It seems i cant delete the thread.. i will mark it as answered

ido_millet
Active Contributor
0 Kudos

Just to confirm I just replicated the problem with my winform, vb.net, vs 2010 viewer app using 13_0_4 and this is indeed a new problem introduced by SP4. 

If a report has a subreport, export to xls causes a crash. Export to xlsx or xls "Data Only" still works.  So, only one of the 3 excel export formats fails.

Former Member
0 Kudos

Hi Ido,

Do you think if its going to be fixed in any upcoming service pack ;

Meanwhile this can work

If ReportDocument.Subreports.Count > 0

       ...

End if

Thank you

ido_millet
Active Contributor
0 Kudos

Nick, I'm not an SAP employee. At this point, it looks like the development team is not yet aware of the export to excel problem.

Yes, checking for subreports and suggesting a Data Only export is one possible way to handle this. Another possibility is to roll back to SP3.

former_member183750
Active Contributor
0 Kudos

Yeah - I reproduced it also. I'll be doing an escalation to R&D, see what they say. To setup expectations; next Service Pack will be released about October. Not sure if this will make it into that SP. If not, we're looking at SP6, ETA.; January 2013.

Other than that, the only options are as described by Ido.

I'll update this thread once I have a TE.

- Ludek

ido_millet
Active Contributor
0 Kudos

Thanks, Ludek!

Nick, please mark Ludek's post as the answer, to close this thread.

0 Kudos

I've set to high in the list of things to do for SP5, since it's a regression issue it should be fix right away.

ADAPT01653219

Thanks again

Don

Former Member
0 Kudos

Hi,

I'm having the same problem also, I use "Crystal report for Visual Studio 2010", Is there any release or download of CR version fixing this issue? I'm looking for downloads of updated "Crystal report for Visual Studio 2010" for a long time that fixes this problem. any response will be kindly appreciated.

Thank you very much.

ido_millet
Active Contributor
0 Kudos

SP5 was just released.  I hope it solves this issue, but I didn't test it yet.

former_member183750
Active Contributor
0 Kudos

Yesterday I was compiling fixed issue documentation (beta: http://wiki.sdn.sap.com/wiki/x/dw-7Eg) and this was one of the issues that came up with a QA tracking number (I was actually the one that duplicated the issue here and created the tracking number). The status in the database is "Not Reproducible with SP5). E.g.; there was no fix done for this as such, however QA was n ot able to repro with SP5 (sometimes magic does happen...).

So far, I have not had the time to test this either, so if anyone is able to download SP 5 and try, that would be great.

- Ludek

Follow us on Twitter

Got Enhancement ideas? Try the SAP Idea Place

Share Your Knowledge in SCN Topic Spaces

0 Kudos

Go to the Overview tab above and on the left you'll see the link to get to the downloads and updates.

Don

Answers (0)