|
-
Apr 6th, 2006, 06:52 AM
#1
Thread Starter
Hyperactive Member
need help in crystal report
hi
im new to crystal report. how can i call it in vb and is there any way to save the report to .pdf file
-
Apr 6th, 2006, 07:00 AM
#2
Re: need help in crystal report
Moved to reporting section.
-
Apr 6th, 2006, 07:20 AM
#3
Thread Starter
Hyperactive Member
Re: need help in crystal report
how can i call crystal report in vb
-
Apr 6th, 2006, 01:25 PM
#4
Re: need help in crystal report
This is a snippet from a VB.Net program I wrote, but you may be able to adapt it to VB:
VB Code:
Imports CrystalDecisions.CrystalReports.Engine
Imports CrystalDecisions.Shared
Dim CrystalReportDocument As ReportDocument
Dim CrystalExportOptions As ExportOptions
Dim CrystalDiskFileDestinationOptions As DiskFileDestinationOptions
Dim Filename As String
CrystalReportDocument = New ReportDocument()
CrystalReportDocument.Load("Path" & "CrystalReportTemplateName.rpt")
Filename = "C:\FileName.pdf"
CrystalDiskFileDestinationOptions = New DiskFileDestinationOptions()
CrystalDiskFileDestinationOptions.DiskFileName = Filename
CrystalExportOptions = CrystalReportDocument.ExportOptions
With CrystalExportOptions
.DestinationOptions = CrystalDiskFileDestinationOptions '<- This is what makes it save the report on disk
.ExportDestinationType = ExportDestinationType.DiskFile
.ExportFormatType = ExportFormatType.PortableDocFormat '<- This is what makes it save it as a pdf document
End With
CrystalReportDocument.Export()
-
Apr 11th, 2006, 03:25 AM
#5
Member
Re: need help in crystal report
what version crystal reports and vb?
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
|