Skip to Content
0
Former Member
Jun 10, 2009 at 09:46 AM

reset flag

155 Views

Hi Experts I need an advice for the below case.

A flag which is set in the EBAN must be reseted. This

is the programm. It doesn't do that. What can be reason for that.

This is the Function Module Call from SAP SRM System with destination command.

CALL FUNCTION 'ZBM_RESET_FLAG'
 DESTINATION 'RV3CLNT888'
  EXPORTING
    BANFNUMBER        = ls_ITEM-EXT_DEMID
 EXCEPTIONS
   NOT_RESETED       = 1
   OTHERS            = 2.

The Function Module is in the the backendsystem (R/3).

FUNCTION ZBM_RESET_FLAG.
*"----------------------------------------------------------------------
*"*"Lokale Schnittstelle:
*"  IMPORTING
*"     VALUE(BANFNUMBER) TYPE  BANFN
*"  EXCEPTIONS
*"      NOT_RESETED
*"----------------------------------------------------------------------

  data lt_eban type table of eban.
  data ls_eban type eban.

  data:  l_r_banfn type table of ZBANFEN.

 SELECT * FROM eban into table lt_eban where BANFN EQ BANFNUMBER AND LOCKFLAG EQ 'X'.

  IF SY-SUBRC IS INITIAL.
    LOOP AT lt_eban INTO ls_eban .
      clear: ls_eban-LOCKFLAG .
      modify eban from ls_eban.
    ENDLOOP.
    ELSE.
    raise NOT_RESETED.
  ENDIF.

ENDFUNCTION.