08-26-2009 5:55 PM
Hi guru,
I have a variable called TPLNR and a selection option S_TPLNR. How do I check whether the TPLNR is in the range of the selection option S_TPLNR? Thanks!
Best regards,
Anthony
08-26-2009 6:01 PM
its based on your declartion of select-options
Ex:
select-options:s_tplnr for tplnr.
or
select-options:s_tplnr for tplnr no-extension.
then
loop at s_tplnr where low <= tplnr and high >= tplnr.
flag = 'X'.
exit.
endloop.
if flag = 'X'.
found
endif.
select-options:s_tplnr for tplnr no intervals.
then
read table s_tplnr with key low = tplnr transporting no fields.
if sy-subrc = 0.
Found
endif.
08-26-2009 6:19 PM
if both of them are defined for same format.
like
data: gv_vbeln type vbeln.
select_options: s_vbeln for vbak-vbeln.
so both these match.
now.
you can put
if gv_vbeln in s_vbeln. "it will check for the value in select option range as you have defined in the screen
endif.
08-26-2009 6:50 PM
08-26-2009 9:18 PM