‎2016 Sep 14 5:41 PM
Dear Techies,
We have developed ABAP program which extracts various data from SAP tables and creates files.
As customer had asked for .XLSX format we gave the same.
Now customer is asking to additionally convert the files into .CSV.
From my ABAP person I understand that our current version of SAP ECC 6.0 does not support this possibility.
I am not very sure if there is any restriction in ECC6.0 version.
Can someone share their experience on this topic.
Regards
Sameer
‎2016 Sep 15 10:20 AM
You are starting in the wrong place.
In your Z program, you extract data, and presumably, before you create an XLSX file, you have all the data in a nice internal table.
Instead of converting your XLSX file to CSV - why not just write a CSV directly out of your internal table?
‎2016 Sep 15 10:30 AM
Hi
Declare an internal table (t_transfer ) with one field ( Line of type char2000 for examp ) ==>
loop at you old internal table into wa.
concatenate wa-field1
wa-field2
.............
wa-field(n)
into wa_transfer-line separated by ';' .
append wa_transfer to T_transfer .
Endloop .
Then use FM GUI_DOWNLOAD or method GUI_DOWNLOAD of class CL_GUI_FRONTEND_SERVICES to transfer you new internal table to a CSV file
Thanks