on 2012 Aug 21 8:46 PM
I am using the following code to export crystal report to a text file. My problem is when there are currency values, the exported text file adds the thousand separator. In Crystal I have removed it in the options menu and when I export from designer the thousand separator is not there.
I don't know why it is being added when I export it with the code.
{code}
Dim myReport As New ReportDocument
myReport.Load(ReportNameAndPath)
Dim CrExportOptions As ExportOptions
Dim CrDiskFileDestinationOptions As New DiskFileDestinationOptions()
Dim CrFormatTypeOptions As New CharacterSeparatedValuesFormatOptions ' ExcelFormatOptions
CrFormatTypeOptions.SeparatorText = ""
CrFormatTypeOptions.Delimiter = ""
CrFormatTypeOptions.ExportMode = CsvExportMode.Standard
CrFormatTypeOptions.ReportSectionsOption = CsvExportSectionsOption.ExportIsolated
CrFormatTypeOptions.GroupSectionsOption = CsvExportSectionsOption.ExportIsolated
CrDiskFileDestinationOptions.DiskFileName = tmpTxtfile
CrExportOptions = myReport.ExportOptions
With CrExportOptions
.ExportDestinationType = ExportDestinationType.DiskFile
.ExportFormatType = ExportFormatType.CharacterSeparatedValues
.DestinationOptions = CrDiskFileDestinationOptions
.FormatOptions = CrFormatTypeOptions
End With
myReport.Export()
(code}
Hi Don,
What version of Cr and VS are you using?
Thanks
Don
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
71 | |
11 | |
10 | |
10 | |
10 | |
8 | |
7 | |
7 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.