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

about parameters..

Former Member
0 Likes
669

hi...

for parameters option how can i check the input value is valid or not

5 REPLIES 5
Read only

Former Member
0 Likes
652

hi

do

at selection-screen.

check for the value entered by user in its master table.

eg: for valid material no.

tables: mara.

parameters: p_matnr like mara-matnr.

at selection-screen.

select single * from mara where matnr = p_matnr.

if sy-subrc <> 0.

error message

endif.

Read only

0 Likes
652

hi..

thanks a lot for replying.

is their any other possibilities fior finding the validating input values in selection-screen.

any function modules..

Read only

0 Likes
652

hi..

thanks a lot for replying..

is their any possibilities to validate the input values in the parameters..

like FM.

plz reply..

Read only

gopi_narendra
Active Contributor
0 Likes
652

Check this code

TABLES : t001.

PARAMETERS : p_ccd TYPE t001-bukrs.

AT SELECTION-SCREEN.
  IF NOT p_ccd IS INITIAL.
    SELECT SINGLE * FROM t001 WHERE bukrs = p_ccd.
    IF sy-subrc NE 0.
      MESSAGE e000(ztest_gopi) WITH 'Incorrect Company Code'.
    ENDIF.
  ENDIF.

Regards

Gopi

Read only

Former Member
0 Likes
652

do the validation in at selection screen on field event...............

reward points if helpful.............