05-10-2017 1:45 PM
We want to fill a custom field in transaction IE36.
So we added the field to RIHFLEET_LIST and use the method FILL_ADD_FIELDS in BADI_EAM_SINGLELEVELLIST.
FIELD-SYMBOLS: <ls_RIFLET20_LIST> TYPE RIHFLEET_LIST.
IF sy-cprog EQ 'RIFLET20' AND IV_STRUCTURE_NAME EQ 'RIHFLEET_LIST'.
ASSIGN cs_object TO <ls_RIFLET20_LIST>.
CHECK <ls_RIFLET20_LIST> IS ASSIGNED.
SELECT SINGLE lkdat
FROM z_leas_zeit
INTO <ls_RIFLET20_LIST>-ZZLKDAT
WHERE equnr EQ <ls_RIFLET20_LIST>-EQUNR
AND aktuell EQ 'X'.
IF sy-subrc EQ 0.
MOVE-CORRESPONDING <ls_RIFLET20_LIST> TO cs_object.
ENDIF.
ENDIF.
The value of cs_object is correct. Also the value in <ls_structure>. But in the ALV it remains empty.
What am I doing wrong?
05-11-2017 7:33 AM
Hi! Did you check if the structure mapped further in the code? It's working only with append structures. Also if you assigned cs_object, it's already filled by SELECT statement and there is no need in the MOVE-CORRESPONDING.
Hope it's helpful
Evgeny
05-11-2017 7:33 AM
Hi! Did you check if the structure mapped further in the code? It's working only with append structures. Also if you assigned cs_object, it's already filled by SELECT statement and there is no need in the MOVE-CORRESPONDING.
Hope it's helpful
Evgeny
05-16-2017 11:17 AM
Hi Evgeny,
with your hint I could find the problem. The append is not direct but indirect (adminfield is 1). When adminfield is 0 it works. So I have to change the structure.
Best regards
Alexander