Skip to Content
0
Former Member
Dec 02, 2008 at 06:29 PM

Adding field in selection sreen and display output

32 Views

Hi,

i got an requirement that to add a field in selection screen i have done that but abgru is reason for rejection if u give in selection screen that reason for rej : Z5 it should come only Z5 related sales orders only but here all the sales orders are displaying ,can any one check this code and correct it ans send me plz.

select-options: s_abgru for vbap-abgru.

DATA: lv_vbtyp LIKE vbak-vbtyp,

lv_bsark LIKE vbak-bsark,

lv_matnr LIKE vbap-matnr,

lv_abgru LIKE vbap-abgru.---->reason for rej

IF NOT s_abgru IS INITIAL.

SELECT SINGLE abgru INTO lv_abgru FROM vbap WHERE abgru IN s_abgru.

IF sy-subrc NE 0.

MESSAGE e000 WITH 'Invalid Reason for Rejection '.

ENDIF.

ENDIF.

i have written this above code .plz correct it and send me /

Thanks in advance,