Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Crystal Reports
Message
 
 
To
26/05/2002 14:16:56
General information
Forum:
Visual Basic
Category:
Database DAO/RDO/ODBC/ADO
Title:
Miscellaneous
Thread ID:
00661492
Message ID:
00664998
Views:
20
Hi Derek,
You need to have two files to use Crystal Reports effectively. The first is the actual crystal report, (let's call it some_report.dsr and it should be in the Designer folder of your project) and then the crystal report viewer (let's call it some_report.frm and it should be in the Forms folder of your project). The code for the form viewer should look something like this:
=======================
Dim Report As New some_report

Private Sub Form_Load()
Screen.MousePointer = vbHourglass
CRViewer1.ReportSource = Report
CRViewer1.ViewReport
Screen.MousePointer = vbDefault

End Sub
=============================
Ensure that the database is verified by going to "Field View" and right clicking on Database Fields then selecting "verify database" (from the some_report.dsr file). Make sure that the "Field Object" and "Text Objects" exist and then you should be able to view the report providing the data is there.

When calling the report from a page just use the same code as you would when calling upon a typical form. i.e. some_report.Show

That should do it!

Max

>Does anyone know how to us CRViewer control in visual basic >to view reports, print, export, search, load, etc. Please any help >would be great


>Derek J. Klingman
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform