cancel
Showing results for 
Search instead for 
Did you mean: 

Newbie Q about Crystal Runtime and VS 2010--multiple data sources & pdf-ing

Former Member
0 Kudos

Hey,

I am working on my first VS2010 application that uses a Crystal Report. In playing w/ sample code, I got a report to show up in the report viewer control.

However, I am really looking for the report to not show up in a viewer at all and just go straight to .pdf and then have the PDF show up on screen. Is this possible? Would anyone care to share a code snippet? I did find code samples to export to .pdf, just not ones that do it without the viewer.

Also, right now, in my testing, I am getting the report to show up in a viewer. However, I am not passing data source info to the report; just using the info in the report itself. I have multiple XML files for the main report and subs (one for the main and one for each of 3 subs). As the path of these xml files will change, how do I tell the report to use one.xml for the main, two.xml for sub 1 and three.xml for sub report 2?

Thanks!

Ed

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hello Ed,

You didn't say if you're developing a Windows or Web application. We have an older document that shows how to export a report and stream it to PDF in a browser - [Printing Web based reports with Crystal Reports for Visual Studio .NET|http://www.sdn.sap.com/irj/boc/index?rid=/library/uuid/600c24a3-ab1d-2b10-1bb4-c50562e353cb]. This code should still work in VS2010.

If you're developing a Windows application you'll have to use a similar process to send the PDF to the user's screen. That part of your application isn't Crystal specific so you'll want to explore MSDN or with Google.

As for your second question - changing XML data at runtime - please create a separate forum thread. Each thread is supposed to be limited to one issue/question.

Sincerely,

Dan Kelleher

Answers (0)