2023 Feb 21 10:18 AM
We are using ALSM_EXCEL_TO_INTERNAL_TABLE to download .XLSX file in to internal table, it is working fine with SAP GUI, But we have assigned this T-code to FIORI using Symentic Object and Catalog ID.
But this ALSM_EXCEL_TO_INTERNAL_TABLE Is not working from FIORI app, Can anyone please suggest is there any alternative solution for this issue.
CALL FUNCTION 'ALSM_EXCEL_TO_INTERNAL_TABLE'
EXPORTING
filename = p_file
i_begin_col = 1
i_begin_row = 1
i_end_col = 250
i_end_row = 60000
TABLES
it_data = gt_exl_data
EXCEPTIONS
inconsistent_parameters = 1
upload_ole = 2
OTHERS = 3.
2023 Feb 21 10:35 AM
I also tried below FM
DATA: it_raw TYPE truxs_t_text_data,OTHERS = 2.
This FM also works fine in SAP GUI, but in Fiori app i am getting error.
2023 Feb 21 11:25 AM
I think that when you access the system through Fiori, you are working in a web based environment. The FM you are asking for work are GUI based ones. So you'll never be able to make them work. You'll need to upload the file (not sure how... FTP?) and then work from there.
2023 Feb 21 12:40 PM
Hello vicen.lozano,
The below FM is working for .CSV from Fiori app also, I am searching for similler FM to read XLSX file.
CALL FUNCTION 'KCD_CSV_FILE_TO_INTERN_CONVERT'
EXPORTING
i_filename = lv_filename
i_separator = ','
TABLES
e_intern = gt_intern
EXCEPTIONS
upload_csv = 1
upload_filetype = 2
OTHERS = 3.
2023 Feb 21 1:53 PM
I think we can not upload .XLSX file from Fiori app.
CONSTANTS c_separator TYPE c VALUE ',' .
DATA: lv_filename TYPE rlgrap-filename.ENDIF.
2023 Feb 21 2:50 PM
ALSM_EXCEL_TO_INTERNAL_TABLE is based on OLE, it can work via SAP GUI, but not via the Web.
You are asking to upload an XLSX file via the Fiori app, you can at least do it with abap2xlsx.