Application Development 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: 

Select options

Former Member
0 Kudos

Hi friends,

Can any one tell me how to check the entries in the input screen for the <b>select option</b> in the selection screen.

Thanx n Regards,

Venu

1 ACCEPTED SOLUTION

anversha_s
Active Contributor
0 Kudos

hi,

chk this code.

SELECT-OPTIONS : s_kunnr for kna1-kunnr.

At selection-screen .

if s_kunnr-low = your condition.

show message.

endif.

like that

if s_kunnr-high = your condition.

show message.

endif.

rgds

anver

if hlped pls mark points

4 REPLIES 4

anversha_s
Active Contributor
0 Kudos

hi,

chk this code.

SELECT-OPTIONS : s_kunnr for kna1-kunnr.

At selection-screen .

if s_kunnr-low = your condition.

show message.

endif.

like that

if s_kunnr-high = your condition.

show message.

endif.

rgds

anver

if hlped pls mark points

Former Member
0 Kudos

We normally don't. Let's say the select option is for customers and the user enters values of '0000000000' to '0000100000'. Neither of these custmers may exist, but there may be many customers in that range.

Rob

Former Member
0 Kudos

Hi Venu,

I hope the below code will help you out..

if the code suits your requirement, reward points.

TABLES MARA.

PARAMETERS: P_MATNR LIKE MARA-MATNR.

AT SELECTION-SCREEN ON P_MATNR.

SELECT SINGLE MATNR

FROM MARA

INTO MARA-MATNR

WHERE MATNR = P_MATNR.

IF SY-SUBRC <> 0.

MESSAGE I000(Z00) WITH 'Material' P_MATNR 'Not Found'.

ENDIF.

--satish

Former Member
0 Kudos

Hi,

Generally you will not check the select-options in the selection screen..

If you still want to do that..Try this..

SELECT-OPTIONS SO_MATNR FOR MARA-MATNR.

AT SELECTION-SCREEN.

SELECT * UP TO ONE ROWS

FROM MARA

WHERE MATNR IN SO_MATNR.

ENDSELECT.

IF SY-SUBRC <> 0.

MESSAGE E000.

ENDIF.

Thanks,

Naren