0 Replies - 736 Views - Last Post: 06 February 2009 - 02:54 AM Rate Topic: -----

#1 masipro  Icon User is offline

  • D.I.C Head

Reputation: 1
  • View blog
  • Posts: 113
  • Joined: 08-July 08

crystal to pdf export

Post icon  Posted 06 February 2009 - 02:54 AM

Hai,
I am using vb6 and Crystal Report. I want to export the report to pdf to a specified location without clicking the export icon. through coding Could it automatically export? please help


Private Sub Command1_Click()
Dim Cry As CRAXDRT.Application
Dim Report As New CRAXDRT.Report
Dim cr As CRAXDRT.ExportOptions

Set Cry = New CRAXDRT.Application

Set Report = Cry.OpenReport(App.Path & "\Leather Requirement Working Report.rpt")

Report.ParameterFields(1).AddDefaultValue dtcCust.Text
Report.ParameterFields(2).AddDefaultValue dtcSeason.Text
Report.ParameterFields(3).AddDefaultValue dtcOrderNo.Text
Report.DiscardSavedData					  'CLEARS REPORT SO WE WORK FROM RECORDSET
					  'LINK REPORT TO RECORDSET
		CRView.ReportSource = Report
		CRView.DisplayGroupTree = False
		CRView.EnableExportButton = True
		CRView.DisplayToolbar = True
		CRView.ViewReport
[b]CRView_ExportButtonclicked = True[/b]


[b]cr.PDFExportAllPages = True[/b]


End Sub



Regards
masipro

Is This A Good Question/Topic? 0
  • +

Page 1 of 1