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 FM

Former Member
0 Likes
484

hi friends,

how should i pass values or range of values or select-options to function module so that it return value in some itab.

with regards

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
467

Hi,

If you want to pass Ranges or select optios to the FM

If you are creating a 'Z' FM

then create a structure with high,low,sign,options

then create a table type using this structure..

then u can pass ranges or select-options to this FM.

if u are using any standard FM then there must be an option to pass ranges..

Regards,

Kiran

4 REPLIES 4
Read only

Former Member
0 Likes
467

in function module u have to create an export parameter...

and u can pass the range of vaues as internal table and can get the resiult.

CALL FUNCTION 'ZTEST'

tables

DATA = itab

result = it_result.

Read only

Former Member
0 Likes
467
Read only

Former Member
0 Likes
468

Hi,

If you want to pass Ranges or select optios to the FM

If you are creating a 'Z' FM

then create a structure with high,low,sign,options

then create a table type using this structure..

then u can pass ranges or select-options to this FM.

if u are using any standard FM then there must be an option to pass ranges..

Regards,

Kiran

Read only

Former Member
0 Likes
467

You can Define the paramters in the Table tab with out referencing to any Data type.

And in the coding part

You move that to appropriate ranges.

TABLES

*" SEL_OPT

data: r_matnr type range of matnr.

r_matnr[] = sel_opt[].

then perform that select using the R_MATNR in where condition.

then return the table data.