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: 

pass values to selection field of another program

Former Member
0 Kudos

HI ABAPers,

I have a select query, i want to pass all the selected values from this query to the

selection screen fields of another program and check how many of these values are executed correctly.

please help me in that.

thanks in advance.

Lokesh

1 ACCEPTED SOLUTION

VB09104
Active Participant
0 Kudos

Hi Lokesh,

You can use internal table of type RSPARAMS which will hold Selection screen values.

Refer to the following code to populate selection fields.

PERFORM populate_sel_screen_values USING:

'P_WERKS' 'P' 'I' 'EQ' wa_tab-werks space,

'S_MESORD' 'S' 'I' 'EQ' wa_tab-aufnr space.

*********************************

FORM populate_sel_screen_values USING pv_selname TYPE any

pv_kind TYPE any

pv_sign TYPE any

pv_option TYPE any

pv_low TYPE any

pv_high TYPE any.

MOVE:

pv_selname TO wa_rspar-selname,

pv_kind TO wa_rspar-kind,

pv_sign TO wa_rspar-sign,

pv_option TO wa_rspar-option,

pv_low TO wa_rspar-low,

pv_high TO wa_rspar-high.

APPEND wa_rspar TO i_rspar.

CLEAR wa_rspar.

ENDFORM.

*****************************************

Regards,

Vikas.

1 REPLY 1

VB09104
Active Participant
0 Kudos

Hi Lokesh,

You can use internal table of type RSPARAMS which will hold Selection screen values.

Refer to the following code to populate selection fields.

PERFORM populate_sel_screen_values USING:

'P_WERKS' 'P' 'I' 'EQ' wa_tab-werks space,

'S_MESORD' 'S' 'I' 'EQ' wa_tab-aufnr space.

*********************************

FORM populate_sel_screen_values USING pv_selname TYPE any

pv_kind TYPE any

pv_sign TYPE any

pv_option TYPE any

pv_low TYPE any

pv_high TYPE any.

MOVE:

pv_selname TO wa_rspar-selname,

pv_kind TO wa_rspar-kind,

pv_sign TO wa_rspar-sign,

pv_option TO wa_rspar-option,

pv_low TO wa_rspar-low,

pv_high TO wa_rspar-high.

APPEND wa_rspar TO i_rspar.

CLEAR wa_rspar.

ENDFORM.

*****************************************

Regards,

Vikas.