Skip to Content
0

Upload xls file from Web transaction

May 02 at 10:45 PM

111

avatar image
Former Member

Dear Colleagues,

I created a tile that run my transaction which upload an xls or xlsx file.

When I run my transaction in sap gui, all works fine I can access to data contained in my file, I'm using the FM 'ALSM_EXCEL_TO_INTERNAL_TABLE'.

With HTML usage this FM doesn't work.

Could you please help me to find an API to convert my xls to sap internal table?

Many Thanks in advance,

Kalthoum.

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

3 Answers

Matthew Billingham
May 03 at 08:15 AM
2

Understand that when you're running a web application, there is no SAPGui. SAPGui handles communications between the application server and the presentation server (your PC). Therefore, when there is no SAPGui (as in a background process, or web applications) any function module that communicates with the presentation server won't work.

If you search, you will find solutions for reading XLSX files programmatically and converting them to internal tables. There are blogs concerning this.

XLS is more difficult as it is not an open standard.

You should also search for convering XLS and XLSX to internal table in background - the same solutions apply as to web applications.

Show 1 Share
10 |10000 characters needed characters left characters exceeded
Former Member

Thanks a lot for your feedback.

I cannot find any solution for my problem.

I found how to convert internal table to XLS, but what I need is how to convert xls or xlsx to internal table using web transaction. Could you pleasse help me?

Many Thanks,

Kalthoum.

0
Srikanth KV May 07 at 11:54 PM
1

try abap2xlsx

check the demo report ZDEMO_EXCEL15. This reads excel files of format .xslx

hope this works :-)

Show 2 Share
10 |10000 characters needed characters left characters exceeded
Former Member

Thank you for your feedback!

Where can I find this program? In which system? Can you assist me?

0

you need to install aba2xslx on your system....this shows the demo program

Follow the installation instructions

0
ROBERTO Forti Santos May 03 at 01:07 AM
0

Hi Kalthoum,

Try these Function Modules

1. CALL FUNCTION 'WWW_LIST_TO_HTML'
... 
2. CALL FUNCTION 'LIST_DOWNLOAD_HTML'
...

Regards,

Show 2 Share
10 |10000 characters needed characters left characters exceeded
Former Member

Hi Roberto,

Thanks a lot for your help.

As importing parameter for this FM LIST_INDEX what shall I put as list_index, I have only the path to my xls file in my program ( my input field to upload the xls file). Could you please clarify to me how I can use this FM on my case?

Many Thanks,

Kalthoum.

0

I'm afraid that Roberto's answer is not relevant to your issue.

0