‎2007 Mar 27 5:55 AM
Hi All,
I am using the Function Module 'TR_OBJECTS_INSERT' to assign entries made in a Z table to a transport request.I am giving the following data.But the FM is giving error "Invalid call sequence for interfaces when recording changes".what could be wrong?
ko200-as4pos = 000000
ko200-pgmi = R3TR
ko200-obje = TABU
ko200-OBJ_name = ZTABLE
XKO200-OBJFUNC = 'K'.
e071k-pgmi = R3TR
e071k-obje = TABU
e071k-objname = ZTABLE
e071k-as4pos = 000000
e071k-mast = tabu
e071k-mastername = ZTABLE
XE071K-SORTFLAG = '2'.
‎2007 Mar 28 8:21 AM
The code is OK
But in the middle why X's are coming
ko200-as4pos = 000000
ko200-pgmi = R3TR
ko200-obje = TABU
ko200-OBJ_name = ZTABLE
<b>XKO200-OBJFUNC = 'K'.</b>
e071k-pgmi = R3TR
e071k-obje = TABU
e071k-objname = ZTABLE
e071k-as4pos = 000000
e071k-mast = tabu
e071k-mastername = ZTABLE
<b>XE071K-SORTFLAG = '2'.</b>
Use only one thing based on Your Data Declarations....
Here os the sample code...
DATA: BEGIN OF LIST_OF_TABLES OCCURS 1.
INCLUDE STRUCTURE KO200.
DATA: END OF LIST_OF_TABLES.
CLEAR LIST_OF_TABLES. REFRESH LIST_OF_TABLES.
LOOP AT E071_TAB.
MOVE-CORRESPONDING E071_TAB TO LIST_OF_TABLES.
APPEND LIST_OF_TABLES.
ENDLOOP.
IF CORR_ACTIV = 'X' OR CORR_CATEGORY = 'SYST'.
CALL FUNCTION 'TR_OBJECTS_INSERT'
EXPORTING
WI_ORDER = CORR_NO
TABLES
WT_KO200 = LIST_OF_TABLES
WT_E071K = E071K_TAB
EXCEPTIONS
CANCEL_EDIT_OTHER_ERROR = 35
SHOW_ONLY_OTHER_ERROR = 36
OTHERS = 37.
IF SY-SUBRC NE 0.
MESSAGE ID SY-MSGID
TYPE 'I'
NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
ENDIF.
Reward if helpful...