Hi,
I am new to oops I have created a small program to display data. I have declared a small struture in the Public section. but when I see the internal table in the debugging mode it contains 2 fields as KEYPART FUNCPART instead of fields which are return in the internal table decleration. and the program in going to dump.
the report is as follows
CLASS TEST DEFINITION.
PUBLIC SECTION.
DATA : BEGIN OF ITAB,
KUNNR TYPE KNA1-KUNNR,
LAND1 TYPE KNA1-LAND1,
NAME1 TYPE KNA1-NAME1,
ORT01 TYPE KNA1-ORT01,
END OF ITAB.
DATA IT_ITAB TYPE STANDARD TABLE OF ITAB.
DATA WA_ITAB TYPE ITAB.
METHODS: DISPLAY,
RETRIEVE_DATA,
PASS_TO_ALV.
ENDCLASS.
CLASS TEST IMPLEMENTATION.
METHOD RETRIEVE_DATA.
SELECT KUNNR LAND1 NAME1 ORT01 FROM KNA1 INTO TABLE IT_ITAB.
ENDMETHOD.
METHOD PASS_TO_ALV.
RETRIEVE_DATA( ).
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
I_STRUCTURE_NAME = 'ITAB'
TABLES
t_outtab = IT_ITAB.
ENDMETHOD.
METHOD DISPLAY.
PASS_TO_ALV( ).
ENDMETHOD.
ENDCLASS.
DATA OBJ_TEST TYPE REF TO TEST.
START-OF-SELECTION.
CREATE OBJECT OBJ_TEST.
please trace out the problem.
Thanks in Advance.