Dear All,
what's wrong with this code ? I have applied a user exit wherein the profit center from line itm will copied to another field in header doc (basicallly BSEG to BKPF). however when i do an f-02 the effect doesnt taes place. I am not sure where to check for errors if any in this code.
FORM U903 CHANGING P_XREF2_HD TYPE BKPF-XREF2_HD.
DATA: L_PRCTR TYPE BSEG-PRCTR.
SELECT SINGLE PRCTR INTO L_PRCTR FROM BSEG
WHERE SHKZG = 'S'.
IF SY-SUBRC = 0.
MOVE L_PRCTR TO P_XREF2_HD.
ENDIF.
ENDFORM.
pls advice. this is the only place where i am stuck now.
best regds
Subha