Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

PO Header Z field is not updated, using classic BADI ME_PROCESS_PO_CUST

Hi Experts,

I have implemented classic badi ME_PROCESS_PO_CUST using interface METHOD if_ex_me_process_po_cust~post.

However the ZZDISPO field i created in PO header is not update, so i tried with standard field which is IHREZ, it is not updated as well. Is it something wrong with my code?

below is my code:

  break abap01.
  DATA: ls_mepoitem TYPE mepoitem,
      ls_mepoheader TYPE mepoheader,
      g_dispo TYPE dispo,
      cl_po TYPE REF TO cl_po_header_handle_mm.

  ls_mepoheader = im_header->get_data( ).

  IMPORT g_dispo TO g_dispo FROM MEMORY ID 'g_dispo'.
  IF g_dispo IS NOT INITIAL.
    ls_mepoheader-zzdispo = g_dispo.
    ls_mepoheader-ihrez = '12345'.

* Updating the Header
    cl_po ?= im_header.
    cl_po->my_ibs_firewall_on = 'X'.
    CALL METHOD im_header->set_data( im_data = ls_mepoheader ).
    CALL METHOD im_header->set_changed( ).
  ENDIF.

Any help is greatly appreciated.

Thanks.

Former Member
Not what you were looking for? View more on this topic or Ask a question