Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi everyone!!
Today i'm trying to export some straight table to CSV file.
I read some discussion here or in other forums, and all suggested to use macro.
I did some tests following their suggestions, but in any case I've found a method that works.
Can someone explain the correct way to export one or more tables in a csv file ??
Thanks
Try this simple macro:
sub exportcsv
set sObject = ActiveDocument.GetSheetObject("CH04")
sObject.Export "c:\myfile.csv", ", "
end sub
where CH04 is the table you want to export
One of the options on the STORE command is CSV.
STORE <table> INTO C:\temp\table.csv (CSV);
Try this simple macro:
sub exportcsv
set sObject = ActiveDocument.GetSheetObject("CH04")
sObject.Export "c:\myfile.csv", ", "
end sub
where CH04 is the table you want to export
Hi,
You need to use macro to export chart data to CSV or export the chart to excel and click Save As and select file type as CSV.
SUB ExportChartToCSV
SET objChart = ActiveDocument.GetSheetObject("CH01")
objChart.Export "C:\Data.CSV", ", "
END SUB
Regards,
Jagan.
Hi, David.
Just a minor correction. I think it should be:
STORE <table> INTO C:\temp\table.csv (txt);
Cheers,
Neil
Hi Jagan,
How to export chart data to csv for more than one chart.
Thanks
Hi,
Try like this
SUB ExportChartToCSV
SET objChart = ActiveDocument.GetSheetObject("CH01")
objChart.Export "C:\Data1.CSV", ", "
SET objChart = ActiveDocument.GetSheetObject("CH02")
objChart.Export "C:\Data2.CSV", ", "
SET objChart = ActiveDocument.GetSheetObject("CH03")
objChart.Export "C:\Data3.CSV", ", "
END SUB
Note : One CSV file can hold only one table data.
Hope this help syou.
Regards,
Jagan.