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: 

selection-screen non-editable field

Former Member
0 Kudos
10,243

HI,

On the selection-screen of a report, i have 2 parameter & one select opttions in selection screen like this sequence

p1 (has F4 help)

s1

p2 (Mandatory field)

If i select p1 value 'create' from F4 help. then depends on this selection from F4 help

s1 should be editiable.

p2 should be non-editable.

If i select p1 value 'dispaly' from F4 help. then depends on this selection from F4 help

s1 should be editiable.

p2 should be editable.

How to acheive this.

1 ACCEPTED SOLUTION

Former Member
0 Kudos
1,406

Hi,

write your code in the event.


AT SELECTION-SCREEN OUTPUT.
IF P1 = <F4 VALUE>.
LOOP AT SCREEN.
IF SCREEN-NAME = 'S1'.
SCREEN-INPUT = '1'.
MODIFY SCREEN.
IF SCREEN-NAME = 'P2'.
SCREEN-INPUT = '0'.
MODIFY SCREEN.
ENDLOOP.
ENDIF.

The second part is similar to the first part try this logic.

Hope this helps.

Aswath.

4 REPLIES 4

Former Member
0 Kudos
1,407

Hi,

write your code in the event.


AT SELECTION-SCREEN OUTPUT.
IF P1 = <F4 VALUE>.
LOOP AT SCREEN.
IF SCREEN-NAME = 'S1'.
SCREEN-INPUT = '1'.
MODIFY SCREEN.
IF SCREEN-NAME = 'P2'.
SCREEN-INPUT = '0'.
MODIFY SCREEN.
ENDLOOP.
ENDIF.

The second part is similar to the first part try this logic.

Hope this helps.

Aswath.

Former Member
0 Kudos
1,406

Try this


tables: vbrk.

parameters:  s_bukrs like vbrk-bukrs,
             s_fkart like vbrk-fkart,
             s_fktyp like vbrk-fktyp.

at selection-screen output.

  loop at screen.

    if screen-name = 'S_FKART' .
      screen-input = 0.
      modify screen.
    endif.

    if screen-name = 'S_FKTYP' .
      screen-input = 0.
      modify screen.
    endif.

    if s_bukrs = '<your f4 input value> '.
      screen-input = 1.
      modify screen.
    endif.
    endloop.

0 Kudos
1,406

SOLVED. Thanks.

0 Kudos
1,406

Hi kelvin,

If yours is solved please make the status of the question answered.

thanks.