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

Generate Parameters Dynamically

pradeep_grandhi
Active Participant
0 Likes
729

Hello All,

Is there any way to generate parameters(even check boxes and radio buttons also) dynamically in my program because I get the parameters from an external source. Can u please tell me?

7 REPLIES 7
Read only

Former Member
0 Likes
701

Hi ,

Yes , It happened...

you use AT SELECTION-SCREEN OUTPUT.

as per your selection screen you define radio button and check box.

use flag as your check box selection and another for radio button selection. As per your requirement you use flag.

Hope this is helpful to you ..

Regards

kamal

Read only

0 Likes
701

Sorry Kamal.

I didn't understand how to proceed with what u said. can you be a bit more clear.

Regards,

Pradeep.

Read only

0 Likes
701

Use the below code in SE38.

SELECTION-SCREEN : BEGIN OF BLOCK b1 WITH FRAME.

PARAMETERS: p_act2 RADIOBUTTON GROUP rad1 USER-COMMAND act DEFAULT 'X',

p_act1 RADIOBUTTON GROUP rad1.

SELECTION-SCREEN : END OF BLOCK b1.

SELECTION-SCREEN : BEGIN OF BLOCK b2 WITH FRAME.

PARAMETERS: rad1 RADIOBUTTON GROUP rad USER-COMMAND radio MODIF ID a,

rad2 RADIOBUTTON GROUP rad MODIF ID b,

rad3 RADIOBUTTON GROUP rad MODIF ID c.

PARAMETERS check AS CHECKBOX USER-COMMAND check MODIF ID d.

PARAMETERS chec1 AS CHECKBOX USER-COMMAND check MODIF ID e.

SELECTION-SCREEN : END OF BLOCK b2.

AT SELECTION-SCREEN OUTPUT.

LOOP AT SCREEN.

IF p_act1 = 'X'.

IF screen-group1 = 'A'.

screen-active = 1.

ENDIF.

IF screen-group1 = 'B'.

screen-active = 1.

ENDIF.

IF screen-group1 = 'C'.

screen-active = 1.

ENDIF.

IF screen-group1 = 'D'.

screen-active = 0.

ENDIF.

IF screen-group1 = 'E'.

screen-active = 0.

ENDIF.

ELSEIF p_act2 = 'X'.

IF screen-group1 = 'D'.

screen-active = 1.

ENDIF.

IF screen-group1 = 'E'.

screen-active = 1.

ENDIF.

IF screen-group1 = 'A'.

screen-active = 0.

ENDIF.

IF screen-group1 = 'B'.

screen-active = 0.

ENDIF.

IF screen-group1 = 'C'.

screen-active = 0.

ENDIF.

ENDIF.

MODIFY SCREEN.

ENDLOOP.

Read only

0 Likes
701

This is my requirement:

I will get a list of select-options, parameters and checkboxes and radio buttons with their details in an excel sheet which may vary in number everytime.I need to process that excel sheet and make them populate in the screen. I hope now you understood

Read only

0 Likes
701

Hi,

Check this command in help GENERATE SUBROUTINE POOL. With it you should be able to generate your screen. However personally I've never used it so I'm not 100% sure if it will cover your case.

Best regards

Marcin Cholewczuk

Read only

0 Likes
701

What you told is not the answer for my question but it was a new thing I have learnt. Thank You...

Regards,

Pradeep.

Read only

0 Likes
701

Hi,

Actually I think the GENERATE SUBROUTINE POOL is the only way to achieve this...

You code a dynamic report with the selection screen you need in an internal table, then use the generate subroutine pool statement and finally call your created selection screen with e.g. a submit statement...

I would love to see other options tough

Kr,

Manu.