Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

SELECT_OPTIONS_RESTRICT

Former Member
0 Likes
895

Using SELECT_OPTIONS_RESTRICT i am able to include only 'Select Single Values' Tab, but my requirement is to include only 'Exclude Single Values' Tab only.

Please help me out in this...Thank You.

5 REPLIES 5
Read only

Former Member
0 Likes
687

Hi,

Try for example

data date type dats.

select-options s_date for date NO-EXTENSION NO INTERVALS.

Reward if helpful.

Regards,

Avishek

Read only

vinod_vemuru2
Active Contributor
0 Likes
687

Hi Reddy,

R U passing sign value as E for the parameter RESTRICTION?

Also check the FM documentation where they have explained with one example.

Thanks,

Vinod.

Read only

0 Likes
687

Actually i am using below code:

tables: mara.

  • Type pools

type-pools: slis, sscr.

  • Selection Screen

select-options:

*_date for sy-datum .

s_no for mara-matnr no intervals.

at selection-screen output.

data: restrict type sscr_restrict,

ass type sscr_ass,

opt_list type sscr_opt_list. "BT,CP,EQ,GE,GT,LE,LT,NB,NE,NP

*equal only

clear opt_list.

opt_list-name = 'JUST_NE'.

opt_list-options-eq = 'X'.

append opt_list to restrict-opt_list_tab.

*apply restrictions to Serial field

clear ass.

ass-kind = 'S'.

ass-name = 'S_NO'.

ass-sg_main = 'I'.

ass-op_main = 'JUST_NE'.

append ass to restrict-ass_tab.

call function 'SELECT_OPTIONS_RESTRICT'

exporting

restriction = restrict

exceptions

too_late = 1

repeated = 2

selopt_without_options = 5

selopt_without_signs = 6

invalid_sign = 7

empty_option_list = 9

invalid_kind = 10

repeated_kind_a = 11

others = 12.

Here i am able to see only 'Select Single Values' , but i need only 'Exlude Single Values' Tab to be appeared.

Thanks...

Read only

Former Member
0 Likes
687

Hi Try this

SELECT-OPTIONS: S_bukrs FOR bkpf-bukrs MEMORY ID buk NO INTERVALS.

Regards,

John Victor

Read only

Former Member
0 Likes
687

Hi Reddy

I encountered at same problem,but as i found out, there is no posibility

to define for this FM Exclude mode,

instead of this i left in Single values screen only one exclude option.

in your code it will look like :

  
*equal only
CLEAR opt_list.
  opt_list-name = 'JUST_NE'.
  opt_list-options-ne = 'X'.
  opt_list-options-bt = ' '.
  opt_list-options-cp = ' '.
  opt_list-options-eq = ' '.
  opt_list-options-ge = ' '.
  opt_list-options-gt = ' '.
  opt_list-options-le = ' '.
  opt_list-options-lt = ' '.
  opt_list-options-nb = ' '.
  opt_list-options-eq = ' '.
  APPEND opt_list TO restrict-opt_list_tab. 

Hope i helped.

Best Regards

Yossi.R.