on 03-11-2008 9:00 AM
I wrote a function.This read codes from a .txt file, create an abap program dinamically and after run it.
I wrote a java program with jco and i wrote an abap program for calling function .İf i runned abap program not happened any problem.But i runned java program.i saw this error :
RFC_ERROR_SYSTEM_FAILURE: Exception condition "CNTL_ERROR" raised.
My function :
FUNCTION Z_MS_FUNC2.
*"----------------------------------------------------------------------
*"*"Local Interface:
*" IMPORTING
*" EXPORTING
*" VALUE(RESULT) TYPE ZMS_SONUC-SONUC
*"----------------------------------------------------------------------
DATA: code TYPE TABLE OF rssource-line.
data : p_file TYPE string.
p_file = 'C:\deneme.txt'.
CALL FUNCTION 'GUI_UPLOAD'
EXPORTING
filename = p_file
FILETYPE = 'ASC'
tables
data_tab = code.
INSERT REPORT 'zms_dinamik002' FROM code.
SUBMIT zms_dinamik002 AND RETURN.
result = 'Successfull.'.
ENDFUNCTION.
this code show error row :
38 CALL METHOD CL_GUI_FRONTEND_SERVICES=>DIRECTORY_LIST_FILES
39 EXPORTING
40 DIRECTORY = FILE
41 FILTER = ''
42 FILES_ONLY = 'X'
43 * DIRECTORIES_ONLY = 'X'
44 CHANGING
45 FILE_TABLE = filetab
46 COUNT = count
47 EXCEPTIONS
48 CNTL_ERROR = 1
49 DIRECTORY_LIST_FILES_FAILED = 2
50 WRONG_PARAMETER = 3
51 ERROR_NO_GUI = 4
52 others = 5.
53
54 IF SY-SUBRC <> 0.
>>>>> RAISE CNTL_ERROR.
56 ENDIF.
deneme.txt
report mehmet.
data wa like zms0005.
wa-jop_id = 14.
wa-jop_name = 'UZAK4'.
modify zms0005 from wa.
Hi,
wa-jop is not defined (data: wa-jop type...)!
Try to insert the coding-lines in a new report. Than make a syntax check.
Regards Mario
Edited by: Mario Müller on Mar 11, 2008 6:47 AM
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
84 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.