2007 Apr 19 5:45 AM
Hi Experts,
i have selection screen like this
in the below one Division and Distibution channel is hard code to 21 and 10,
but need sales organization 1000 & 1100 have
Division and Distibution channel is hard code to 20 and 20.
How will write the logic in selection screen.
SELECT-OPTIONS : KUNNR FOR KNA1-KUNNR .
PARAMETER : VKBUR LIKE KNVV-VKBUR OBLIGATORY.
PARAMETER : VKORG LIKE KNVV-VKORG OBLIGATORY.
PARAMETER : SPART LIKE KNVV-SPART DEFAULT '21' NO-DISPLAY.
PARAMETER : VTWEG LIKE KNVV-VTWEG DEFAULT '10' NO-DISPLAY.
SELECT-OPTIONS : SPBUP for S001-SPBUP OBLIGATORY.
Thanks & Regards,
Sreedhar.
2007 Apr 19 5:50 AM
Hi.
Write like this
to give more than one value have to declare select-options and in the intialization you have to write the code
SELECT-OPTIONS : KUNNR FOR KNA1-KUNNR .
PARAMETER : VKBUR LIKE KNVV-VKBUR OBLIGATORY.
select-options: VKORG for KNVV-VKORG no intervals OBLIGATORY.
PARAMETER : SPART LIKE KNVV-SPART DEFAULT '20' NO-DISPLAY.
PARAMETER : VTWEG LIKE KNVV-VTWEG DEFAULT '20' NO-DISPLAY.
SELECT-OPTIONS : SPBUP for S001-SPBUP OBLIGATORY.
In the initialization Event.
write
s_vkorg-low = '1000'
s_vkorg-sign = 'I'.
s_vkorg-option = 'EQ'.
append s_vkorg.
s_vkorg-low = '1100'
s_vkorg-sign = 'I'.
s_vkorg-option = 'EQ'.
append s_vkorg.
use this s_vkorg in where condition of the select statement
reward if useful
regards,
Anji
2007 Apr 19 5:51 AM
INITIALIZATION.
if vkorg eq '1000' or
vkorg eq '1100'.
spart = '20'.
vtweg = '20'.
endif.