2005 Nov 17 1:27 PM
Hello,
In a report data must be read from an XLS file. I'm using function ALSM_EXCEL_TO_INTERNAL_TABLE, which returns data into a table of type alsmex_tabline, the problem is that the field alsmex_tabline-value which contains cell value is define as type char(50). I need to read from XLS fields with length greater than 50 (300 to 500).
Is it a way to read from XLS files cell values with length more than 50 characters?
Thank you!
Bogdan
2005 Nov 17 1:49 PM
Hi,
Can you please check OSS note:188950
The following is few parts of this note.
Symptom
In the legacy data transfer via Microsoft Excel with Transaction AS100, the system only incompletely copies field contents that are longer than 32 characters.
Affected are the two asset description fields as well as leasing and insurance text.
Additional key words
TXT50, TXA50, LETXT, VSZTX
Cause and prerequisites
The problem is due to a program error.
Solution
Implement the advance corrections.
Before you implement the source code changes, create structure ALSMEX_TABLINE in the dictionary in the development class AALSM (see also Note 10960):
Call up Transaction SE11, enter "ALSMEX_TABLINE" as data type, select "Data type" and choose "Create". On the following dialog box choose 'Structure'.
Make up a short text and enter the following values in the "Component" and "Component type" columns on the "Components" tab in the table control:
ROW KCD_EX_ROW_N
COL KCD_EX_COL_N
VALUE CHAR50
Activate the structure.
Finally you must include the structure in a function module interface:
Call up Transaction SE37. Enter function module "ALSM_EXCEL_TO_INTERNAL_TABLE" and choose "Change".
On the "Tables" tab in the table control, change the type spec. and reference type of the "INTERN" parameter. Change "TYPE" to "LIKE" and "KCDE_INTERN" to "ALSMEX_TABLINE".
Activate the function module.
Source code corrections
Thanks,
Ramakrishna
2005 Nov 17 1:49 PM
Hi,
Can you please check OSS note:188950
The following is few parts of this note.
Symptom
In the legacy data transfer via Microsoft Excel with Transaction AS100, the system only incompletely copies field contents that are longer than 32 characters.
Affected are the two asset description fields as well as leasing and insurance text.
Additional key words
TXT50, TXA50, LETXT, VSZTX
Cause and prerequisites
The problem is due to a program error.
Solution
Implement the advance corrections.
Before you implement the source code changes, create structure ALSMEX_TABLINE in the dictionary in the development class AALSM (see also Note 10960):
Call up Transaction SE11, enter "ALSMEX_TABLINE" as data type, select "Data type" and choose "Create". On the following dialog box choose 'Structure'.
Make up a short text and enter the following values in the "Component" and "Component type" columns on the "Components" tab in the table control:
ROW KCD_EX_ROW_N
COL KCD_EX_COL_N
VALUE CHAR50
Activate the structure.
Finally you must include the structure in a function module interface:
Call up Transaction SE37. Enter function module "ALSM_EXCEL_TO_INTERNAL_TABLE" and choose "Change".
On the "Tables" tab in the table control, change the type spec. and reference type of the "INTERN" parameter. Change "TYPE" to "LIKE" and "KCDE_INTERN" to "ALSMEX_TABLINE".
Activate the function module.
Source code corrections
Thanks,
Ramakrishna
2005 Nov 17 2:56 PM
2005 Nov 22 12:39 PM
Hi,
so what Ramakrishna says is make your own copy of the SAP-standard fm ALSM_EXCEL_TO_INTERNAL_TABLE as well as from the structure ALSMEX_TABLINE, and define the length of the field VALUE 300 or 500.
br, juha