Hi together,
I am trying to use the method CHECK_TSK_AT_SAVE of the BadI: CEWB_TSK_UPDATE. Now the code that I have written is:
DATA: lr_ref TYPE REF TO if_ex_cewb_tsk_update,
lt_tsk TYPE STANDARD TABLE OF cpcl_tsk_plko_type.
* CREATE OBJECT lr_ref.
CALL METHOD lr_ref->check_tsk_at_save
EXPORTING
i_tsk_data = lt_tsk
* i_mtk_data =
* i_seq_data =
* i_plas_data =
* i_opr_data =
* i_com_data =
* i_prt_data =
* i_cha_data =
* i_chv_data =
* i_pac_data =
* i_mst_data =
EXCEPTIONS
inconsistency_found = 1
OTHERS = 2.
IF sy-subrc <> 0.
* Implement suitable error handling here
ENDIF.
I get the dump: CX_SY_REF_IS_INITIAL, that the interface is not yet initiated, thus we cannot use the method.Can anyone tell me how can I get reference or initiate the lr_ref that I have declared?
Thanks,
R