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: 

screen -invisble

spandana_babu
Participant
0 Kudos

hi experts,

I HAVE DOUBT ON INVISIBLE BUTTON

i am taking two push buttons p1 ,p2

if i am click on p1, same time p2 will invisible.

plz send me code realted to this functionality, with simple example

regards

Anand

1 ACCEPTED SOLUTION

Former Member
0 Kudos

Hi Anand,

When user clicks the button p1, capture the user action (okcode) in the PAI of the screen. i.e) your MODULE USER_COMMAND INPUT.

This you can simply do by assigning values.

<b>save_okcode = okcode.</b> (okcode should be defined in the attributes of the screen)

Then in the PBO where the screen is generated, you can make the button p2 to become invisible by looping thru the System table SCREEN which has all the attributes of the screen elements like this...

<b>MODULE Status_100 OUTPUT.

Case save_okcode.

When 'p2'. </b>" p2 is the function code for button p2 defined in screen<b>

loop at screen.

if screen-name = 'p2'.

screen-invisible = 1.

endif.

endloop.

endcase.</b>

That will change button p2 's status to invisible and display.

Hope that helps!

regards,

Naveenan.

2 REPLIES 2

tushar_shukla
Active Participant
0 Kudos

use system table SCREEN . here u can set the invisible property of 2nd pushbutton true when first pushbutton is triggered.

and use the follwing code in PAI.

module user_commond input.

case sy-ucomm.

when 'fcode1'.

loop at screen .

if screen-name = 'p2'.

screen-invisible = 1.

modify screen.

endcase.

endmodule.

Message was edited by:

TUSHAR SHUKLA

Former Member
0 Kudos

Hi Anand,

When user clicks the button p1, capture the user action (okcode) in the PAI of the screen. i.e) your MODULE USER_COMMAND INPUT.

This you can simply do by assigning values.

<b>save_okcode = okcode.</b> (okcode should be defined in the attributes of the screen)

Then in the PBO where the screen is generated, you can make the button p2 to become invisible by looping thru the System table SCREEN which has all the attributes of the screen elements like this...

<b>MODULE Status_100 OUTPUT.

Case save_okcode.

When 'p2'. </b>" p2 is the function code for button p2 defined in screen<b>

loop at screen.

if screen-name = 'p2'.

screen-invisible = 1.

endif.

endloop.

endcase.</b>

That will change button p2 's status to invisible and display.

Hope that helps!

regards,

Naveenan.