‎2008 Jul 03 8:25 AM
what is the syntax
AT SELECTION-SCREEN OUTPUT.
what does the following code do?
AT SELECTION-SCREEN OUTPUT.
LOOP AT SCREEN.
IF screen-name CS 'EN_EBELN'.
screen-invisible = 1.
screen-input = 0.
ENDIF.
IF screen-name CS 'EN_EKORG'.
screen-invisible = 1.
screen-input = 0.
ENDIF.
MODIFY SCREEN.
ENDLOOP.
the report uses a logical database ENM
thanks for the help.
‎2008 Jul 03 10:05 AM
hi,
AT SELECTION-SCREEN OUTPUT is the selection screen event which is trigerred before the list is being displayed. It is PBO event you can say.
This is triggered when the selection screen is loaded in memory before being displayed. We can change the appearence and values of the fields before display and after INITIALIZATION.
Hope this will help.
Regards
Sumit Agarwal
‎2008 Jul 03 8:27 AM
based on the screen-name it will make some field modifiable.. some invisible
SCREEN is a SAP standard structure which will hold data related to the selection screen or the screen elements.
‎2008 Jul 03 8:32 AM
SCREEN is an intertnal table,
which has the fields like,
input, invisible....
AT SELECTION-SCREEN OUTPUT u can make a few fields visible, few rady for input and few not... like that.
for example, u have 2 fields number, name as screen fields.
While displaying the screen u don't want the name filed ready for input.
dat time u loop at screen and make sreen-input = 0. like that....
screen-invisible = 0 --- whether u want to display dat field on screen or not....
‎2008 Jul 03 8:34 AM
If the selection screen contains any element having string EN_EBELN in it the it will make that particular element invisible and make it no editable similar is the case wid en_ekorg.
well i think the code is redundant as if u r setting screen-invisible=1 them it wud be invisible then thr's no question of making it editable or non editable with screen-input.
hope i helped.
reward if useful.
regards,
kartik
‎2008 Jul 03 8:34 AM
Hi,
AT SELECTION-SCREEN OUTPUT is an event in which we can handle the screen elements dynamically.
For Example if a radio button on the selection is selected , field 'A' is to be invisable.
This can be achived Using
Loop at screen.
endloop.
Regards,
Jaya Vani
‎2008 Jul 03 8:35 AM
Hi,
The code makes the fields invisible that have the strings EN_EBELN, EN_EKORG in their field names .
Regards,
Wajid Hussain P
Edited by: Wajid Hussain P on Jul 3, 2008 1:06 PM
‎2008 Jul 03 8:52 AM
Test this code understand the logic:
*&---------------------------------------------------------------------*
*& Report ZTEST_SOURAV9
*&
*&---------------------------------------------------------------------*
*&
*&
*&---------------------------------------------------------------------*
REPORT ztest_sourav9.
PARAMETERS:
p_desk RADIOBUTTON GROUP 1 DEFAULT 'X' USER-COMMAND flag, "Desktop location
p_unix RADIOBUTTON GROUP 1 , "Unix location
p_file1 LIKE rlgrap-filename MODIF ID m1 DEFAULT 'File 1' ,
p_file2 LIKE filename-fileextern MODIF ID m2 DEFAULT 'File 2'.
AT SELECTION-SCREEN OUTPUT.
LOOP AT SCREEN.
IF p_desk = 'X' AND
screen-group1 = 'M2'.
screen-active = '0'.
ELSEIF p_unix = 'X' AND
screen-group1 = 'M1'.
screen-active = '0'.
ENDIF.
MODIFY SCREEN.
ENDLOOP.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_file1.
*....
AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_file2.
*...
START-OF-SELECTION.
IF p_desk = 'X'.
WRITE: p_file1.
ELSE.
WRITE: p_file2.
ENDIF.
‎2008 Jul 03 9:53 AM
Hi,
This is making some fields ( the fields whose names contains the strings 'EN_EBELN' or 'EN_EKORG') invisble and disabling the input (ie, that field is not open for input) while displaying the selection screen.
Regards,
Soumya.
‎2008 Jul 03 10:02 AM
Hi,
AT SELECTION-SCREEN OUTPUT event is triggered just before the screen is displayed .And if you want to make any visibility changes of fields which are there on the selection screen,you can do it here.
The attributes of all fields of a screen are stored in the system table SCREEN.
This can be edited line by line using LOOP AT SCREEN ... ENDLOOP.
Changes to the properties of the attributes of the current screen field can be put into effect using MODIFY SCREEN.
When evere you make any changes to the attributes of the field then use MODIFY SCREEN.
Regards ,
Rajitha.
‎2008 Jul 03 10:05 AM
hi,
AT SELECTION-SCREEN OUTPUT is the selection screen event which is trigerred before the list is being displayed. It is PBO event you can say.
This is triggered when the selection screen is loaded in memory before being displayed. We can change the appearence and values of the fields before display and after INITIALIZATION.
Hope this will help.
Regards
Sumit Agarwal