Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Using CRViewer to View Multi Reports

Status
Not open for further replies.

vbneil54

Programmer
Sep 11, 2001
14
US
After making a report using the RDC, then making a report using Crystal. How can I get the same viewer to show each report depending on the report file name.
 
May be give an if statement where u are specifying report path with some conditions for opening separate reports
 
I don't think your understanding. Or I'm not explaining it right.

report1 (designed using Crystal)
report2 (designed using RDC)

currently report2 shows when I run the CRViewer.

I can't find a property to change the report. I don't want to add another form and CRViewer to view report1.

I can do it if I use the OCX and not the viewer, but there has to be a way to change the report no matter where it was created and show it using the CRViewer.

Please help.
 
The code to attach a report to the viewer is the same in either case:

CRViewer1.ReportSource = Report
CRViewer1.ViewReport

It's what "Report" is and how it's created that's different. You probably cannot avoid having 2 separate Dim statements, one for the report made as an .RPT and one for the report that is a .DSR file inside of the VB app. And some IF ELSE to assign the right report to .ReportSource.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top