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

how we write the logic for label in print program?

Former Member
0 Likes
736

hi experts,

i need to print the two labels in the output

when i select 3s label then we go that selection screen and when we select 4s label then we go to 4s label selection screen

how we write logoc for this.

plzz help me

thnaks.

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
638

Hi,

You can use create two radio buttons and depending on the 3s or 4s radio button ,u can call the next screen.

Here is the sample similar code:

PARAMETERS: p_file1 TYPE c RADIOBUTTON GROUP a DEFAULT 'X'

USER-COMMAND uc01,

p_date TYPE c RADIOBUTTON GROUP a.

PARAMETERS: p_pres TYPE c RADIOBUTTON GROUP b MODIF ID 001,

p_appl TYPE c RADIOBUTTON GROUP b MODIF ID 001.

AT SELECTION-SCREEN OUTPUT.

LOOP AT SCREEN.

IF screen-group1 EQ '001'.

IF p_file1 EQ 'X'.

screen-active = '1'.

ELSE.

screen-active = '0'.

ENDIF.

MODIFY SCREEN.

ENDIF.

ENDLOOP.

MODIFY SCREEN.

Regards,

Rama.

hi experts,

i need to print the two labels in the output

when i select 3s label then we go that selection screen and when we select 4s label then we go to 4s label selection screen

how we write logoc for this.

plzz help me

thnaks.

3 REPLIES 3
Read only

Former Member
0 Likes
638

Hi Friend,

In your code write two selection screens block with * SELECTION-SCREEN BEGIN OF SCREEN <SCRN1>..SELECTION-SCREEN END OF SCREEN*

Now if it is 3s ticked, then call the first selection screen like: CALL SELECTION-SCREEN <SCRN1>

and <SCRN2> for 4s.

Hope it will help you.

Regards

Krishnendu

Read only

Former Member
0 Likes
639

Hi,

You can use create two radio buttons and depending on the 3s or 4s radio button ,u can call the next screen.

Here is the sample similar code:

PARAMETERS: p_file1 TYPE c RADIOBUTTON GROUP a DEFAULT 'X'

USER-COMMAND uc01,

p_date TYPE c RADIOBUTTON GROUP a.

PARAMETERS: p_pres TYPE c RADIOBUTTON GROUP b MODIF ID 001,

p_appl TYPE c RADIOBUTTON GROUP b MODIF ID 001.

AT SELECTION-SCREEN OUTPUT.

LOOP AT SCREEN.

IF screen-group1 EQ '001'.

IF p_file1 EQ 'X'.

screen-active = '1'.

ELSE.

screen-active = '0'.

ENDIF.

MODIFY SCREEN.

ENDIF.

ENDLOOP.

MODIFY SCREEN.

Regards,

Rama.

Read only

Former Member
0 Likes
638

hi,

you can go like this:

case sy-ucomm.

when 3s.

call screen 3s.

when 4s.

call screen 4s.

endcase.

Hope this helps you.

thanks,

Sneha