Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

How to read text with several lines from excel to an internal table

Former Member
0 Kudos

I have used function ALSM_EXCEL_TO_INTERNAL_TABLE several times to read data from excel an store it in an internal table.

Now I have long texts in excel fields. With this function the maximun character read are 50.

I need to be able to read text with several lines from excel and I would´nt want to split words.

How could I do it?

Thanks in advance.

4 REPLIES 4

Former Member
0 Kudos

Please check below , might be helpful.

http://wiki.sdn.sap.com/wiki/display/ABAP/UploadExceldocumentintointernal+table

Edited by: Chetan Singh Shekhawat on Nov 24, 2011 1:20 PM

0 Kudos

It´s not working. It does the same thing that my code. It just reads the first 50 characters of the excel´s cell.

Former Member
0 Kudos

Hi,

That function uses OLE statements to actually open, copy workbooks to cliboard, import it to sap and map retrieved content to internal table by splitting each rows at tabulation. The only limitation here is due to the type of output table (value field is a fixed 50 len char field)... So, to avoid this limitation I would suggest to get inspired from the FM code and do the upload yourself with OLE commands... However, there are perhaps other working FM for such a case, but I doubt it!

You can find plenty of examples here or on the web for doing this with OLE commands...

Kr,

Manu.

Former Member
0 Kudos

hi

Use TEXT_CONVERT_XLS_TO_SAP FM

Thanks

Gupta