‎2012 Feb 07 3:32 PM
Hey guys,
I'm getting a run time error in my program and would appreciate any help.
I'm getting a table name from the user and then downloading that table's contents to whatever directory they pick.
It works fine on all my tables except EBAN. I've converted everything to text (so I can add a pipe delimiter) and then sent it to download, but EBAN is fighting me.
Here's the relevant code:
DATA:
tb_converted(4096) TYPE c OCCURS 0,
itab1 TYPE STANDARD TABLE OF eban, wa_eban TYPE eban,
SELECT * FROM eban INTO CORRESPONDING FIELDS OF TABLE itab1.
CLEAR tb_converted.
CALL FUNCTION 'SAP_CONVERT_TO_TEX_FORMAT'
EXPORTING i_field_seperator = del_char
TABLES i_tab_sap_data = itab1
CHANGING i_tab_converted_data = tb_converted
EXCEPTIONS CONVERSION_FAILED = 1 OTHERS = 2.
CALL FUNCTION 'GUI_DOWNLOAD'
EXPORTING FILENAME = temp_str
TABLES DATA_TAB = tb_converted.
I use a similar cluster of code for all my other tables possible for Download and it works fine (examples are eine, ekko). I know the error is in the converting part.
Here is the Error:
UC_OBJECTS_NOT_CHARLIKE
The current ABAP program "SAPLTRUX" had to be terminated because it has come across a statement that cannot be executed.
For the statement " IF ... op1 CO op2 ... " only character-type data objects are supported at the arguement position 'op1'.
In this case the operand 'op1' has the non-character-type 'I'. The current program is a Unicode program..... etc...etc..
Thanks in advance.
gilthan3
Edited by: gilthan3 on Feb 7, 2012 4:33 PM
‎2012 Feb 07 3:54 PM
Your best bet is to debug and see on which field he chokes. (or see if the dump list has more detailed information)
You may need to do some converting yourself before passing EBAN to the function module.
‎2012 Feb 07 3:54 PM
Your best bet is to debug and see on which field he chokes. (or see if the dump list has more detailed information)
You may need to do some converting yourself before passing EBAN to the function module.