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

regd : passing variants on screen from calling program to called program.

Former Member
0 Likes
455

hi,

i need to pass the screen variants from one program to standard program.

i used

submit <program name> via selection-screen

with <select-options> and return

It is moving to called screen but it is not displaying the screen variants which i entered in calling program .please help me in this

surely points will be rewarded

3 REPLIES 3
Read only

Former Member
0 Likes
435

Hi

u must use Selection-sets addition.

SUBMIT REPORT01

VIA SELECTION-SCREEN

USING SELECTION-SET 'VARIANT1'

USING SELECTION-SETS OF PROGRAM 'REPORT00'

AND RETURN.

if u r dynamically cretaing the Variants from ur calling program , then u must use the RSPARAMS structure.

Reward with points if helpful.

Regards,

Naveen

Message was edited by:

Naveen Deva

Read only

gopi_narendra
Active Contributor
0 Likes
435

Check this code

data : var(13) type c.
var = 'INACTIVEUSERS'.

SUBMIT zrsusr200 USING SELECTION-SET var TO SAP-SPOOL
       WITHOUT SPOOL DYNPRO
       SPOOL PARAMETERS pripar
       ARCHIVE PARAMETERS arcpar
       AND RETURN.

Regards

Gopi

<b>make sure the variant exists in that particular systesm(DEV/QA/PRD) for that program</b>

Message was edited by:

Gopi Narendra

Read only

Former Member
0 Likes
435

HI,

see this example.

Program accessed

REPORT report1.

DATA text TYPE c LENGTH 10.

SELECTION-SCREEN BEGIN OF SCREEN 1100.

SELECT-OPTIONS: selcrit1 FOR text,

selcrit2 FOR text.

SELECTION-SCREEN END OF SCREEN 1100.

...

Calling program

REPORT report2.

DATA: text TYPE c LENGTH 10,

rspar_tab TYPE TABLE OF rsparams,

rspar_line LIKE LINE OF rspar_tab,

range_tab LIKE RANGE OF text,

range_line LIKE LINE OF range_tab.

...

rspar_line-selname = 'SELCRIT1'.

rspar_line-kind = 'S'.

rspar_line-sign = 'I'.

rspar_line-option = 'EQ'.

rspar_line-low = 'ABAP'.

APPEND rspar_line TO rspar_tab.

range_line-sign = 'E'.

range_line-option = 'EQ'.

range_line-low = 'H'.

APPEND range_line TO range_tab.

range_line-sign = 'E'.

range_line-option = 'EQ'.

range_line-low = 'K'.

APPEND range_line TO range_tab.

SUBMIT report1 USING SELECTION-SCREEN '1100'

WITH SELECTION-TABLE rspar_tab

WITH selcrit2 BETWEEN 'H' AND 'K'

WITH selcrit2 IN range_tab

AND RETURN.

rgds,

bharat.