Skip to Content

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

Reg: Error massege

Hi All,

I have return a code in userexit

there is a message in the code

for that message i want to display field data

for which item it is getting error

like 10 or 20

the item number should display.

IF SY-TCODE EQ 'ME21N'.

LOOP AT TEKPO.

CLEAR : TMP_PREIS.

SELECT SINGLE PREIS FROM EBAN INTO TMP_PREIS

WHERE BANFN = TEKPO-BANFN AND

BNFPO = TEKPO-BNFPO.

IF SY-SUBRC EQ 0.

TMP_PER = TMP_PREIS * '0.1'.

TMP_LESS = TMP_PREIS - TMP_PER.

TMP_HIGH = TMP_PREIS + TMP_PER.

IF ( TEKPO-NETPR < TMP_LESS OR TEKPO-NETPR > TMP_HIGH ).

MESSAGE 'Allowed Tolerance Limit for PO w.ref to PR 10%' TYPE 'E' .

ENDIF.

ENDIF.

ENDLOOP.

ENDIF.

thanks

kavi

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