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: 

Hide input field in dialog

former_member193107
Participant
0 Kudos

Dear Expert,

I tried to hide input field in dialog program using this code below.

But somehow when I make it invisible, the value in that field is also gone.

How do you maintain the value in that input field when you make it invisible?

thanks

IF screen-name = 'FIELD1'.
       screen-INVISIBLE = '1'.
       Screen-active = 0.
       MODIFY SCREEN.
       CLEAR screen.
 ENDIF.
1 ACCEPTED SOLUTION

0 Kudos

Hello Sam Indra,

If I understand it right,the field trying to invisible in run time but use the value in it for further selection criteria.

In this scenario you can use the Function Module "DYNP_VALUES_READ" to get the value of selection screen at run time but before your logic to make it invisible.

Pallavi

4 REPLIES 4

former_member1716
Active Contributor

Sam Indra,

Why do you want to know the value of the field which is anyway not visible?

Under what scenario you are making it Invisible?

Solution is simple Just transfer the Data in the field to another Variable and then make it Invisible.

Am still not clear with your requirement though, can you explain further in detail?

former_member557245
Participant

Hi Sam,

Could you explain in more detail?

0 Kudos

Hello Sam Indra,

If I understand it right,the field trying to invisible in run time but use the value in it for further selection criteria.

In this scenario you can use the Function Module "DYNP_VALUES_READ" to get the value of selection screen at run time but before your logic to make it invisible.

Pallavi

Sandra_Rossi
Active Contributor
0 Kudos

No issue with my test program, the variable HIDDEN still contains the value "A" after pressing Enter:

PARAMETERS hidden DEFAULT 'A' MODIF ID hid.
PARAMETERS bb DEFAULT 'B'.

AT SELECTION-SCREEN OUTPUT.
  LOOP AT SCREEN.
    IF screen-group1 = 'HID'.
      screen-invisible = '1'.
      screen-active = 0.
      MODIFY SCREEN.
      CLEAR screen.
    ENDIF.
  ENDLOOP.

AT SELECTION-SCREEN.
  BREAK-POINT.