Data Connectivity
 Crystal Reports Forum : Crystal Reports 9 through 2020 : Data Connectivity
Message Icon Topic: export problems Post Reply Post New Topic
Author Message
smoky
Newbie
Newbie
Avatar

Joined: 31 Aug 2011
Location: Germany
Online Status: Offline
Posts: 6
Quote smoky Replybullet Topic: export problems
    Posted: 12 Dec 2012 at 5:44am
Hallo, I'm working with VB 6 and crystal 11.2 Iwoild like to export a report direct without looking at it or printing. Who can help. My code follows:               Set crApplication = New CRAXDRT.Application

Set crReport1 = crApplication.OpenReport(App.Path & "\BerichteCrystal10\ElsterBilanzAPGV.rpt", 1)

crReport1.DiscardSavedData
crReport1.Database.SetDataSource adoRS

'CRViewer1.ReportSource = crReport1
'CRViewer1.ViewReport

If fs.FolderExists(Pfad & "\Elster" & FirmenNr & "") = False Then
    fs.CreateFolder (Pfad & "\Elster" & FirmenNr & "")
End If

If fs.FolderExists(Pfad & "\Elster" & FirmenNr & "\Elster" & Bilanzjahr) = False Then
    fs.CreateFolder (Pfad & "\Elster" & FirmenNr & "\Elster" & Bilanzjahr)
End If

If fs.FileExists(Pfad & "\Elster" & FirmenNr & "\Elster" & Bilanzjahr & "\ElsterBilanz_" & Bilanzjahr & ".ttx") = True Then
    fs.DeleteFile (Pfad & "\Elster" & FirmenNr & "\Elster" & Bilanzjahr & "\ElsterBilanz_" & Bilanzjahr & ".ttx")
End If

Dim FileName As String
FileName = "" & Pfad & "\Elster" & FirmenNr & "\Elster" & Bilanzjahr & "\ElsterBilanz_" & Bilanzjahr & ".ttx" crReport1.ExportOptions.FormatType = crEFTTabSeparatedText
crReport1.ExportOptions.DestinationType = crEDTDiskFile
crReport1.ExportOptions.DiskFileName = FileName
crReport1.Export
Many thanks in advance from Germany SMOKY






smoky
IP IP Logged
Post Reply Post New Topic
Printable version Printable version

Forum Jump
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum



This page was generated in 0.016 seconds.