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

Make fields display only

Former Member
0 Likes
3,321

Hi,

I want to make the screen fields(simple and table fields) display only after the click of one button in the screen. How can i do this.

Help Please

Regrds

Priya

13 REPLIES 13
Read only

Former Member
0 Likes
2,484

Hello,

U can do this using loop at screen.

  • LOOP AT SCREEN.

  • IF SCREEN-GROUP1 = 'SC1'.

  • SCREEN-INPUT = '0'.

  • SCREEN-OUTPUT = '1'.

  • MODIFY SCREEN.

  • ENDIF.

  • ENDLOOP.

U can try like this .

If useful reward points.

Regards,

Vasanth

Read only

Former Member
0 Likes
2,484

Hi

U have to use LOOP AT SCREEN/ENDLOOP statament in PBO:

PROCESS PBO.

MODULE MODIFY_SCREEN.

MODULE MODIFY_SCREEN.

IF ........

LOOP AT SCREEN.

IF SCREEN-NAME = <FIELD NAME>.

SCREEN-INPUT = 0.

MODIFY SCREEN.

ENDIF.

ENDLOOP.

ENDIF.

ENDMODULE.

Max

Read only

dani_mn
Active Contributor
0 Likes
2,484

HI,

Create a button and give it function code 'DISABLE'

then write this code.

IF ok_code = 'DISABLE'.

LOOP AT SCREEN.

IF screen-name = 'FIELD1' OR

screen-name = 'FIELD2'.

screen-input = 0.

MODIFY screen.

ENDIF.

ENDLOOP.

CLEAR: ok_code.

ENDIF.

REgards,

Wasim Ahmed

Message was edited by: Wasim Ahmed

Read only

Laxmana_Appana_
Active Contributor
0 Likes
2,484

Hi,

Check this code:

LOOP AT SCREEN.

IF ( screen-name EQ 'TEST_DESC' ).

IF ( X_active_flag IS INITIAL ).

  • Deactivate, do not appear on screen

screen-active = 0.

screen-input = 0.

ELSE.

  • Activate, appear on screen

screen-active = 1.

screen-input = 1.

ENDIF.

MODIFY SCREEN.

ENDIF.

ENDLOOP.

Regards

Appana

Read only

Former Member
0 Likes
2,484

Hi,

you need to loop at screen and modify the screen table.

loop at screen.
if screen-name = scrfieldname.
screen-input = 0.
modify screen.
endif.
endloop.

Regards

vijay

Read only

Former Member
0 Likes
2,484

loop at screen.

if screen-fieldname = 'Mzater'.

SCREEN-INPUT = '0'.

modify screen.

endif.

endloop.

Read only

0 Likes
2,484

Hi ,

this code is not working at all.

I tried it . Just give an alternative for it

screen-input = 0.

modify screen.

endif.

Read only

0 Likes
2,484

Hi,

Can you show your Flow logic PBO/and PAI. the way of coding might be wrong.

Regards

vijay

Read only

0 Likes
2,484

HI,

where you are writing this code ? in PBO or PAI.

You have to write this in some PBO module.

IN your PBO flow logic create a module.

MODULE disable_fields.

In your program define this module.

MODULE disable_fields OUTPUT.

LOOP AT screen.

IF screen-name = 'your_field'.

screen-input = 0.

MODIFY screen.

ENDIF.

ENDLOOP.

ENDMODULE.

REgards,

Wasim Ahmed

Read only

Former Member
0 Likes
2,484

First assign a group to all of your fields that u want to make disable. Suppose this is SC1.

After that u use this......

LOOP AT SCREEN.

IF SCREEN-GROUP1 = 'SC1'.

SCREEN-INPUT = '0'.

MODIFY SCREEN.

ENDIF.

ENDLOOP

Regards

Abhishek Purwar

Read only

Former Member
0 Likes
2,484

Where are u using this is it in report?

If u r using it in report make sure that u r using it in event

AT selection-screen output.

initially make these fields invisible and after pressing the button check for the sy-ucom code and do the further processing.

loo at scree.

modify screen stuff

Read only

Former Member
0 Likes
2,484

Hi,

Goto se51->field attributes->program->output only

Regards,

Amole

Read only

Former Member
0 Likes
2,484

Forgot to mention we have a field screen-invisible

use this.