cancel
Showing results for 
Search instead for 
Did you mean: 

How to export to Application without Saving to Disk

02-02-2017 7:04 AM
1417 views 3 comments Go to solution
0 Likes
SAP Managed Tags
Subscribe

Hi,

We've recently converted from using the activeX Crystal Runtime to .net runtime 13.0.18 and I'm trying to figure out how I can export a crystal report to another format such as PDF/Excel/etc and opening it up in the default program without saving it to disk.

In the activeX runtime, we simply had

report.ExportOptions.DestinationType = {&crEDTApplication}.

report.Export(false).

Where {&crEDTApplication} is globally defined as the enumerator for exporting to Application (in this case it's simply integer 5).

How do I do this in .net programming? I can't see any ExportDestinationType enums for Exporting to application in https://technet.microsoft.com/en-us/library/security/ms226377(v=vs.80).aspx

Thanks!

0 Likes

Accepted Solutions (1)

Accepted Solutions (1)

0 Likes

Hi Xin,

See this example on how to enable exporting to destination application:

https://support.wdf.sap.corp/sap/support/notes/0001765153

It works great...

Don

Answers (2)

Answers (2)

Former Member
0 Likes

Thanks for your reply, János. That's what we're currently doing but I find it much slower than in the past when we used the ActiveX control and was able to export straight to application.

Is there no way to do this at all? We currently use Report.ExportToDisk, but I can see the ExportToStream method, would that work?

Janos_NAGY-SAP
Product and Topic Expert
Product and Topic Expert
0 Likes

Hello

You may export it into a temp folder, than open the application from the temoorary space. When the application closes, do a cleanup.

You can do it in a thread, which handles the export, opens the application and do the cleanup.

Regards,

János