04-09-2008 10:39 AM
Hi All,
I want to export data into local file. The line of internal table is greater than 1023 characters. I have used List->Export->Local File.... But when I open that file in excel the data is wrapped (here with wrapping I mean the fields of the internal table comes in two rows of the excel sheet and so is the data). I want my record to be in a single row in the excel sheet.
Thanks & Regards,
Bhaskar Tripathi
04-09-2008 10:59 AM
Hi,
try with below code
Use Function moduleSCMS_STRING_TO_FTEXT to split lengthy strings into lines to desired lengths.
You can declare flext_tab with only one field of desired length.
Write the contents of this internal table by looping ...
Regards
Sreeni
04-09-2008 10:55 AM
Hi,
Try downloading into a flat file and then open it in excel. Check if this solves your problem.
Regards,
Siddhesh S.Tawate
04-09-2008 10:59 AM
Hi,
try with below code
Use Function moduleSCMS_STRING_TO_FTEXT to split lengthy strings into lines to desired lengths.
You can declare flext_tab with only one field of desired length.
Write the contents of this internal table by looping ...
Regards
Sreeni
04-09-2008 11:25 AM
Use the function module SAP_CONVERT_TO_XLS_FORMAT to download the internal table to an excel file.
Regards,
Venkat.O
DATA: t100_lines TYPE STANDARD TABLE OF t001 WITH DEFAULT KEY.
PARAMETERS: p_file LIKE rlgrap-filename DEFAULT 'c:\tmp\test.xls'.
SELECT * FROM t001
INTO TABLE t100_lines.
CALL FUNCTION 'SAP_CONVERT_TO_XLS_FORMAT'
EXPORTING
i_filename = p_file
TABLES
i_tab_sap_data = t100_lines.