|
-
Sep 6th, 2005, 04:52 AM
#1
Thread Starter
Addicted Member
How To Set Up CR 8.5 Report With VB6
Hi guys ...
I using VB6 and CR8.5.
Now I try to open a pre-design report which made using CR8.5 and saved as report file with .rpt extension.
What references i should use to open this report? For your note, i don't want to use Crystal 8.5 Designer.
Thanks in advance.
-
Sep 6th, 2005, 05:30 AM
#2
Re: How To Set Up CR 8.5 Report With VB6
rpt files can only be opened and modified by using the Crystal Report Designer.
-
Sep 6th, 2005, 07:40 AM
#3
Re: How To Set Up CR 8.5 Report With VB6
Are you asking about what references to add to allow the user to print or view the report from your application using the Crystal APIs?
Sometimes the Programmer
Sometimes the DBA
Mazz1
-
Sep 6th, 2005, 08:18 PM
#4
Thread Starter
Addicted Member
Re: How To Set Up CR 8.5 Report With VB6
I want to view the report on a new window using CR viewer.
-
Sep 7th, 2005, 07:40 AM
#5
Re: How To Set Up CR 8.5 Report With VB6
If using the CR Viewer OCX then Select Project--> Components --> Controls and select the Crystal report control (crystal32.ocx). This will add the view control to the tools. If you want to do it on your own then the API selections I use add the following references to the project: Crystal Report 7 ActiveX Designer Design Time Library (Internal) (craxddt.dll), Crystal Report 8.5 ActiveX Designer Design Time (craxdrt.dll), Crystal Reprot Engine 7 Object Library (cpeaut32.dll).
Sometimes the Programmer
Sometimes the DBA
Mazz1
-
Sep 7th, 2005, 08:09 PM
#6
Thread Starter
Addicted Member
Re: How To Set Up CR 8.5 Report With VB6
Well, a little confused about that. Can you give me an example project for this? Thanks.
-
Sep 8th, 2005, 07:36 AM
#7
Re: How To Set Up CR 8.5 Report With VB6
I will generate a small app using both methods later today and post.
Sometimes the Programmer
Sometimes the DBA
Mazz1
-
Sep 8th, 2005, 08:46 AM
#8
-
Sep 9th, 2005, 06:30 AM
#9
Thread Starter
Addicted Member
Re: How To Set Up CR 8.5 Report With VB6
thanks for the code sample.
i also try different way using craxdrt.dll, crviewer.dll, crviewer.oca.
What the difference between using crystal report activex designer runtime library and crystal report engine object library?
here is my code:
VB Code:
Dim crApp As New CRAXDRT.Application
Dim crReport As New CRAXDRT.Report
Set crReport = crApp.OpenReport(App.Path & "\Reports\ICPShipment.rpt")
frmViewer.crView.ReportSource = crReport
frmViewer.crView.ViewReport
frmViewer.Show vbModeless, Me
Set crReport = Nothing
Set crApp = Nothing
But i have problem with that code, why everytime i run that code always give me an error "server has not yet been opened"?
But when i try to open an empty report, it just work fine.
Last edited by LeonX; Sep 9th, 2005 at 07:18 AM.
Regards,
Ferry
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|