Incorrect result using the function ALSM_EXCEL_TO_INTERNAL_TABLE
I have used the function ALSM_EXCEL_TO_INTERNAL_TABLE to load a Excel sheet on an internal table and the function returns the following result:
Row Col Value
0001 0001 902000100 A601 K 627542130 021 AGARDUN ZMAS 673 EU
0002 0001 902000101 A602 K 627542131 022 AGARDUN ZMAS 695 EU
0003 0001 902000102 A603 K 627542132 023 AGARDUN ZMAS 717 EU
0004 0001 902000103 A604 k 627542133 024 AGARDUN ZMAS 739 EU
0005 0001 902000104 A605 k 627542134 025 AGARDUN ZMAS 761 EU
0006 0001 902000105 A606 W 627542135 026 AGARDUN ZMAS 783 EU
0007 0001 902000106 A607 W 627542136 027 AGARDUN ZMAS 805 EU
0008 0001 902000107 A608 W 627542137 028 AGARDUN ZMAS 827 EU
0009 0001 902000108 A609 K 627542138 029 AGARDUN ZMAS 849 EU
0010 0001 902000109 A610 k 627542139 030 AGARDUN ZMAS 871 EU
0011 0001 902000110 A611 O 627542140 031 AGARDUN ZMAS 893 EU
That is to say, the excel sheet has nine columns, and the function thinks that only has 1 column.
I have checked the function with the same file in other computers, and the result has been the correct one, that is to say, the function returns the value of the column in its corresponding column:
Row Col Value
0001 0001 902000100
0001 0002 A601
0001 0003 K
0001 0004 627542130
0001 0005 021
0001 0006 AGARDUN
0001 0007 ZMAS
0001 0008 673
0001 0009 EU
0002 0001 902000101
0002 0002 A602
0002 0003 K
0002 0004 627542131
0002 0005 022
0002 0006 AGARDUN
0002 0007 ZMAS
0002 0008 717
0002 0009 EU
Can you help me?
Thanks.
Hi Garduño,
1. U want to upload data from EXCEL
into internal table.
2. and u are using ALSM_EXCEL_TO_INTERNAL_TABLE.
3. But We cannot do this direclty !
For uploading purpose :
6. There are TWO options.
a) either save the excel to TAB Delimited file,
and use GUI_UPLOAD to upload the data in internal table.
b) use FM for excel purpose.
7. a) is easy and recommended
8. b) there is a FM for it,
but we have to apply some more logic
bcos the FM uploads data of excel
in the intenal table,
CELL BY CELL
9. afTER THAT , we have to convert this cell by cell data,
into our format of internal table.
10. use this code (just copy paste in new program)
(it is tried wit T001 structure data)
(it will AUTOMATICALLY based upon the
fields of internal table,
convert data from cell by cell,
to that of internal table fields)
REPORT abc.
DATA : ex LIKE TABLE OF alsmex_tabline WITH HEADER LINE.
DATA : t001 LIKE TABLE OF t001 WITH HEADER LINE.
DATA : cmp LIKE TABLE OF rstrucinfo WITH HEADER LINE.
DATA : col TYPE i.
DATA : col1 TYPE i.
FIELD-SYMBOLS : .
DATA : fldname(50) TYPE c.
CALL FUNCTION 'ALSM_EXCEL_TO_INTERNAL_TABLE'
EXPORTING
filename = 'd:def.xls'
i_begin_col = 1
i_begin_row = 1
i_end_col = 100
i_end_row = 100
TABLES
intern = ex
EXCEPTIONS
inconsistent_parameters = 1
upload_ole = 2
OTHERS = 3.
BREAK-POINT.
CALL FUNCTION 'GET_COMPONENT_LIST'
EXPORTING
program = sy-repid
fieldname = 'T001'
TABLES
components = cmp.
LOOP AT ex.
AT NEW row.
IF sy-tabix = ex-value.
ENDLOOP.
BREAK-POINT.
regards,
amit m.
Similar Messages
-
Hello, everybody, who know how to use the function READ_TEXT
Hello , everybody, I came across a program in which there is a function READ_TEXT, what is it used for ? please specify the parameters id object
. Thank you in advance, mate.
Best regards
Frank
CALL FUNCTION 'READ_TEXT'
EXPORTING
CLIENT = SY-MANDT
id = '0207'
language = sy-langu
name = tmp_name
object = 'VBBK'
ARCHIVE_HANDLE = 0
LOCAL_CAT = ' '
IMPORTING
HEADER =
TABLES
lines = text_itab
EXCEPTIONS
id = 1
language = 2
name = 3
not_found = 4
object = 5
reference_check = 6
wrong_access_to_archive = 7
OTHERS = 8Refer this link:
http://help.sap.com/saphelp_nw04/helpdata/en/d6/0db764494511d182b70000e829fbfe/frameset.htm
READ_TEXT provides a text for the application program in the specified work areas.
The function module reads the desired text from the text file, the text memory, or the archive. You must fully specify the text using OBJECT, NAME, ID, and LANGUAGE. An internal work area can hold only one text; therefore, generic specifications are not allowed with these options.
After successful reading, the system places header information and text lines into the work areas specified with HEADER and LINES.
If a reference text is used, SAPscript automatically processes the reference chain and provides the text lines found in the text at the end of the chain. If an error occurs, the system leaves the function module and triggers the exception REFERENCE_CHECK.
Function call:
CALL FUNCTION 'READ_TEXT'
EXPORTING CLIENT = SY-MANDT
OBJECT = ?...
NAME = ?...
ID = ?...
LANGUAGE = ?...
ARCHIVE_HANDLE = 0
IMPORTING HEADER =
TABLES LINES = ?...
EXCEPTIONS ID =
LANGUAGE =
NAME =
NOT_FOUND =
OBJECT =
REFERENCE_CHECK =
WRONG_ACCESS_TO_ARCHIVE =
Export parameters:
CLIENT
Specify the client under which the text is stored. If you omit this parameter, the system uses the current client as default.
Reference field: SY-MANDT
Default value: SY-MANDT
OBJECT
Enter the name of the text object to which the text is allocated. Table TTXOB contains the valid objects.
Reference field: THEAD-TDOBJECT
NAME
Enter the name of the text module. The name may be up to 70 characters long. Its internal structure depends on the text object used.
Reference field: THEAD-TDNAME
ID
Enter the text ID of the text module. Table TTXID contains the valid text IDs, depending on the text object.
Reference field: THEAD-TDID
LANGUAGE
Enter the language key of the text module. The system accepts only languages that are defined in table T002.
Reference field: THEAD-TDSPRAS
ARCHIVE_HANDLE
If you want to read the text from the archive, you must enter a handle here. The system uses it to access the archive. You can create the handle using the function module ACHIVE_OPEN_FOR_READ.
The value '0' indicates that you do not want to read the text from the archive.
Reference field: SY-TABIX
Default value: 0
Import parameters:
HEADER
If the system finds the desired text, it returns the text header in this parameter.
Structure: THEAD
Table parameters:
LINES
The table contains all text lines that belong to the text read.
Structure: TLINE
Exceptions:
ID
The text ID specified in the parameter ID does not exist in table TTXID. It must be defined there together with the object of the text module.
LANGUAGE
The parameter LANGUAGE contains a language key that does not exist in table T002.
NAME
The parameter NAME contains the name of a text module that does not correspond to the SAPscript conventions.
Possible errors:
The field contains only blanks.
The field contains the invalid characters * or ,.
OBJECT
The parameter OBJECT contains the name of a text object that does not exist in table TTXOB.
NOT_FOUND
The system did not find the specified text module.
REFERENCE_CHECK
The text module to be read has no text lines of its own but refers to the lines of another text module. This reference chain can include several levels. For the current text, the chain is interrupted, that is, one of the text modules referred to in the chain no longer exists.
WRONG_ACCESS_ TO_ARCHIVE
The exception WRONG_ACCESS_TO_ARCHIVE is triggered if an archive is accessed using an incorrect or non-existing archive handle or an incorrect mode (that is, read if the archive is open for writing or vice versa).
Raja T -
Regarding how to use the function module *control_form* in scripts
HI friends,
Can any one tell why and where do we use the function module control_form in scripts. Can you give me a small scenario how to use in scripts.hi satish,
by using this function module we can pass the control
commands to FORM THROUGH ABAP/4 PROGRAM.
see the following example:
TABLES: kna1.
DATA: BEGIN OF it_kna1 OCCURS 0,
kunnr LIKE kna1-kunnr,
name1 LIKE kna1-name1,
ort01 LIKE kna1-ort01,
land1 LIKE kna1-land1,
END OF it_kna1.
DATA:records TYPE i,
window TYPE i value 1.
select-options:s_kunnr for kna1-kunnr.
SELECT kunnr name1 ort01 land1 FROM kna1 INTO TABLE it_kna1
where kunnr in s_kunnr.
CALL FUNCTION 'OPEN_FORM'
EXPORTING
form = 'ZSCRIPT4'
language = sy-langu.
LOOP AT it_kna1.
CALL FUNCTION 'WRITE_FORM'
EXPORTING
element = 'ELE1'
function = 'SET'
type = 'BODY'
window = 'MAIN'.
DESCRIBE TABLE it_kna1 LINES records.
IF window lt records.
window = window + 1.
CALL FUNCTION 'CONTROL_FORM'
EXPORTING
command = 'NEW-WINDOW'
EXCEPTIONS
UNOPENED = 1
UNSTARTED = 2
OTHERS = 3
ENDIF.
ENDLOOP.
CALL FUNCTION 'CLOSE_FORM'
IMPORTING
RESULT =
RDI_RESULT =
TABLES
OTFDATA =
EXCEPTIONS
UNOPENED = 1
BAD_PAGEFORMAT_FOR_PRINT = 2
SEND_ERROR = 3
SPOOL_ERROR = 4
CODEPAGE = 5
OTHERS = 6
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
thanks,
raji -
I can't use the function of "print to video".
I've recently purchased FCPX and Blackmagic Design Decklink HD Extreme 3(version 7.5.2) but I already know this combination looks quite weird because I'm using only DSR. This is the first time I have installed FCP.
I installed FCPX and figured out there's no way to get the video from Decklink on FCPX so that I deleted FCPX, installed FCP 2009 instead and installed FCPX again on the same disk as Final Cut Pro 7... It's a shame to get rid of it.
At first, I could get a good result when printing to tape. There's no problem. But it's not long before I failed to get what i wanted. VCR detects input signal from FCP 7 through Decklink but the monitor of VCR shows only noise. For now, I can't use the function of "print to video".
Also, I connect the input of Decklink to the output of DSR and the output of Decklink to the input of DSR at the same time and monitor w/ the output of DSR. However, the output on the monitor shows something weird when I capture the video from DSR as if the signal is fed back.
Someone told me that I have to use other version of decklink but i'm not sure it would be better if I just change the version.
What's wrong?
What should I do for fixing these all mess?I've recently purchased FCPX and Blackmagic Design Decklink HD Extreme 3(version 7.5.2) but I already know this combination looks quite weird because I'm using only DSR. This is the first time I have installed FCP.
I installed FCPX and figured out there's no way to get the video from Decklink on FCPX so that I deleted FCPX, installed FCP 2009 instead and installed FCPX again on the same disk as Final Cut Pro 7... It's a shame to get rid of it.
At first, I could get a good result when printing to tape. There's no problem. But it's not long before I failed to get what i wanted. VCR detects input signal from FCP 7 through Decklink but the monitor of VCR shows only noise. For now, I can't use the function of "print to video".
Also, I connect the input of Decklink to the output of DSR and the output of Decklink to the input of DSR at the same time and monitor w/ the output of DSR. However, the output on the monitor shows something weird when I capture the video from DSR as if the signal is fed back.
Someone told me that I have to use other version of decklink but i'm not sure it would be better if I just change the version.
What's wrong?
What should I do for fixing these all mess? -
I am going to run tests that require an actuator to move using various types of arbitrary waveforms such as sine or square. The NI 7344 is hooked to the UMI that is going through a driver for a servo valve. The loop is analog and it is closed. I have played with some of the examples but can't get it to work. I have used the function generator VI to generate a signal but I think I am using the wrong input VI to the motion control board. When I use what I have it moves the servo and then stops. It doesn't continually generate the signal.
I would love to use the controls on the function generator vi to control frequency and amplitude ect. Any help or pointer would be helpful. Thank you in advance.Hello,
I'm not clear on exactly how you want to use the generated data but I'm assuming they will be used as your target points.
There's a built-in example for motion called 'One-Axis Contour Move.vi'. This example demonstrates how to provide your target points as 1-D array. All you need to do is to replace the input array with the output of the function generator. In order to have it run continuously, use a while loop. You can further program your application so that it'll change the waveform on the fly by monitoring the user interface but this might be little little tricky as you will need to reset the move and load the new generated points while keeping track of your current position.
I hope this helps. Let me know if you have further questions regarding this
application.
Best regards,
Yusuf C.
Applications Engineering
National Instruments -
Error while using the function module..pack_handling_unit_dlvry
Hi all...
while using the function module pack_handling_unit_dlvry,
we need to pass the handling unit number as per the functionality we require.
but the mandatory field for the function module is the handling unit number in the form of bar code..
so how to use this function module..
All the useful answers will be regarded..
Regards,
Saroja.Have you tried using BAPI BAPI_HU_CREATE. Also view Function Module Documentation on its usage.
-
How to use the function ' CRM_INTLAY_ANALYZE_DATA '?
Hi Experts,
I am working in a scenario where I need to get the GUID of a complaint transaction even before the complaint transaction is saved.I can get that using the function 'CRM_INTLAY_GET_HEADER_GUID' .I also want to get the codegroup and the code associated with the complaint .For that I want to use the function 'CRM_INTLAY_ANALYZE_DATA'. This function has got an import parameter 'IT_ITF_CHANGED_FIELD' which is of type tabletype 'CRMT_ITF_CHANGEDFIELD_TAB' . the line type of this table type is 'CRMT_ITF_CHANGEDFIELD' .In it there is a field called 'REF_GUID' .I populate only this field using the guid returned from 'CRM_INTLAY_GET_HEADER_GUID' .
But no values are coming in the export parameter 'ET_SUBJECT' of the function.
I think I am missing something.
Please give some solution as it is very urgent.
Thanks,
Samrat DuttaHi Experts,
I am working in a scenario where I need to get the GUID of a complaint transaction even before the complaint transaction is saved.I can get that using the function 'CRM_INTLAY_GET_HEADER_GUID' .I also want to get the codegroup and the code associated with the complaint .For that I want to use the function 'CRM_INTLAY_ANALYZE_DATA'. This function has got an import parameter 'IT_ITF_CHANGED_FIELD' which is of type tabletype 'CRMT_ITF_CHANGEDFIELD_TAB' . the line type of this table type is 'CRMT_ITF_CHANGEDFIELD' .In it there is a field called 'REF_GUID' .I populate only this field using the guid returned from 'CRM_INTLAY_GET_HEADER_GUID' .
But no values are coming in the export parameter 'ET_SUBJECT' of the function.
I think I am missing something.
Please give some solution as it is very urgent.
Thanks,
Samrat Dutta -
I have a photo of an ice surface and another of a flower. Now I want to create a merged photo with the flower lying under the ice. I understand that I shall use the function "Layer" and have even read in the manual and looked on a video, but that information is not sufficiently detailed for me. I have tried several options, but I come now way. Generally it seems that your information is only for the ones who can, not for the people who can´t although it is we who really need to learn. Please give me a step by step (click by click) information on how I can get the ice above the flower and then make the ice partly transparent so the flower is seen underneath. Please send me an e-mail Erik Solbu [email protected]
Open a new document big enough for your image. Then additional open your ice and flower image as well. Copy each and paste it into your blank document. They will be placed on their own separate layers.
Make sure in your layers panel. (Bottom right) the ice is above the flower, by dragging it in place. In that same layers panel click the ice layer to select in and find the opacity meter above. Drag to the left until you get the effect you desire. -
Why can't I use the function of menu item 'issue delivery output'?
why can't I use the function of menu item 'issue delivery output' in main screen of delivery note?
And at the same time I can't use the button of printing in main screen of delivery note.
the main screen of delivery note I mean above is in screen of maintaining shipping data instand of the first screen of VL02N.
TKS in advance.Hi,
Because delivery will be having header level output and item level output. So if u try to print through main screen then system will not know whether it is header related or item related. That is the reason it is only print output at header level or item level but not in main screen.
I think u may have doubt like how billin will be issued output through Main screen. Because for billing both header and item level data are same..
Regards
Sankar -
I am using a web application that requires the use of the F7 key. Actually, to be more precise, I need the functionality that you would get on a PC if you hit Ctrl-F7 while in this web application in Firefox. I have changed the Mac's settings to allow standard use of the function keys (rather things like volume up/down, etc.) However, when I try to use Ctrl-F7 it appears to be using the function that is built into Firefox browser rather than the web application running within Firefox. (FYI, nothing happens when I try Cmd-F7 or Alt/Option-F7 either).
Leliforever, cheek you list of installed add-ons, the Ask toolbar can be installed without the users knowledge.
For checking other extensions that may cause this, follow the procedure in this link - https://support.mozilla.com/kb/Troubleshooting+extensions+and+themes -
How to use the function module 'HR_ES_FEATURE_BACKFIELD'
Hi,
How to use the function module 'HR_ES_FEATURE_BACKFIELD'?
I need the usage from both technical as well as functional point of view.
What is the use of this function module and technically how it is to be used to retrieve a feature for a particular employee.hey iam from functional side can u be little bit clear of that feature
thanks
sikindar -
Hi fellow apple guys, i have this problem. Hope you can help me. I don't know how to use the function keys (F1 to F12) on my macbook air. Pls help
Out of the box, to use the function keys as function keys, hold down the fn key when you press the key. Otherwise, you get the picture function on the key. You can reverse this behavior in the Keyboard system prefs.
-
Hey i hav an hp pavilion g series n i would like to kno how use the function keys without having to
hey i hav an hp pavilion g series n i would like to kno how use the function keys without having to click on the fn + function key
Hi,
You can change this in your system bios as described in the link below.
http://h10025.www1.hp.com/ewfrf/wc/document?docname=c02035108&cc=us&dlc=en&lc=en&jumpid=reg_R1002_US...
Regards,
DP-K
****Click the White thumb to say thanks****
****Please mark Accept As Solution if it solves your problem****
****I don't work for HP****
Microsoft MVP - Windows Experience -
how can i configure my wireless keyword so i can use the Function <F> keys to control volume etc...? I am using 10.5.8 OS
little wireless cameras would not have the ability to send back to the base, even thought the base can reach it.
Now if you take regular cameras and wire them into a Cisco switch that was attached to a wireless bridge that could shine back to the base...now you might have something, but your still going to have to do a survey/path analysis to determine if it is feasible.
Coverage isnt throughput. I see one base station with 3 or 4 sectoral antennas depending on direction, pointing two several distribution bridges to bridge the gaps that go out again to the cameras...something like that. And all of it should be higher in the air than your construction. -
Elvis: Is It possible to use the Function Generator and the Oscilloscope simultaneously?
Hi,
We are using the NI Elvis to output a function or a sine wave at a certain frequency and using the oscilloscope on the same board/elvis to read a modified signal. Is this possible? Can we use both the Function Generator and the oscilloscope at the same time? Please help. The oscilloscope would be reading signal from an accelerometer. Thank you in advance. We have no VI as we do not know which to use and if they are possible.Hi,
There is no problem using the Function Generator and Oscilloscope
at the same time with NI ELVIS. Using the NI ELVIS soft front panels (Start
>> Programs >> National Instruments >> NI ELVIS 3.0 >>
NI ELVIS – see picture attached –‘NI ELVIS soft front panels.JPG’), you can choose
to open more than one instrument at a time. We do this by opening one
instrument, allowing it to begin, and then opening another. We can also program
in LabVIEW using more than one instrument at a time by placing down multiple
Express VI’s taken from the NI ELVIS pallet on the block diagram (see picture
attached – ‘ELVIS Express VI's (LabVIEW).JPG’). One note when doing this,
please see KB 41ODPHX1
for an example of how to program in parallel. If you do not wire the ‘stop’
terminal of the express VI’s, you will get the error described.
David L.
Systems Engineering
National Instruments
Attachments:
ELVIS Express VI's (LabVIEW).JPG 74 KB
NI ELVIS soft front panels.JPG 56 KB
Maybe you are looking for
-
Execution time difference between SELECT & UPDATE statement in JDBC Sender.
Hi Experts, In my scenario, I have used the JDBC Sender Adapter with the SELECT and UPDATE statement. Now the problem is in between the execution of Select and update statement, few more entries are coming in the same DB Table. So result of this is u
-
Upgrade from CRM2007 (6.0) to CRM 7.0
Hi community, we are working on an upgrade from 6.0 to 7.0. After checking modifications with TA SPAU, I'm checking our adaption in the WebUI. Extending a WD Component with the workbench means, that a Z class is generated which inherits from the SAP
-
MSI: Warning 25702. Failed to uninstall PrepDrvr.Sys for Software Metering Agent
hello all, Iam having same problem of uninstalling sccm agent 2012. I get the error "MSI: Warning 25702. Failed to uninstall PrepDrvr.Sys for Software Metering Agent". i have used the command ccmsetup /uninstall but it did not work. i also used msiex
-
Hi, How to transform a Logical DG to a standalone (11.2.0.2) Thanks in advance
-
Not enough space on new 16gb 4S to restore my backup from my lost 32gb 4S
So here is the issue. I had a 32GB iPhone 4S. It was stolen but I have it backed up on my computer. I could only afford to replace it with a 16GB iPhone 4S. When I go to restore my new phone from the backup I get the error message that there isnt