‎2007 Nov 23 7:07 PM
what is at selection screen ,
at selection screen-ouput,
at selection screen-on value request,
at selection screen on help request,
at selection screen on field,
at selection screen radio button,
at selection screen on block?
explain each one plzzzzzzzzz iam really confusing?
‎2007 Nov 24 2:09 AM
Different Types of Selection Screens
What is:
1. at selection-screen on field
2. at selection-screen output
3. at selection-screen block
4. at selection-screen on value-request
5. at selection-screen on help-request and their difference?
For knowing Selection-screens:
First you must have right understanding of Events.
- Events are introduced by Event Keyword. They end when again next processs begins.
Selection-screens are special screen defined in ABAP.
- This ABAP at run time only controls the flow logic of Selection-screens. The PBO and PAI triggers the num of. selection-screens.
The basic form of the selection screen events is the AT SELECTION-SCREEN event. This event occurs after the runtime environment has passed all input data from the selection screen to the ABAP program. The other selection screen events allow programmers to modify the selection screen before it is sent and specifically check user input.
"At Selection-screen OUTPUT is trigerred in PBO of selection-screen.
- This allows you to modify the Selection-screen, before it is displayed.
"At Selection-screen On Field is triggered in PAI of selection-screens.
- The input fields can b checked,in the corresponding event block. If an error message occurs within this event block, the corresponding field is made ready for input again on the selection screen.
"At Selection-screen On Block is trigerred in PAI event.
- You define a block by enclosing the declarations of the elements in the block between the statements SELECTION-SCREEN BEGIN OF BLOCK block - END OF BLOCK block. You can use this event block to check the consistency of the input fields in the block.
"At Selection-screen On value request.
- This event is trigerred for F4 help.
"At Selection-screen On help request .
- This event is triggered when the user clicks F1 for help on fileds.
Reward points if it is usefull.....
Girish
‎2007 Nov 23 7:43 PM
Hi Akash,
Check these links which explains about your statements.
http://www.sts.tu-harburg.de/teaching/sap_r3/ABAP4/selectio.htm
http://www.sts.tu-harburg.de/teaching/sap_r3/ABAP4/at_selec.htm
Thanks,
Vinay
‎2007 Nov 23 8:11 PM
Hi,
At selection screen-output:
In the PBO of the selection screen, the event is triggered. This event block allows you to modify the selection screen directly before it is displayed
At selection screen-on value request:
The event is triggered when the user calls the F4 help for the field <field>. If no corresponding event block has been defined, the possible values help from the ABAP Dictionary is displayed, or none at all if the field has no Dictionary reference. If a corresponding event block exists, it takes precedence over the default possible values help mechanism. It is then up to the programmer to ensure that an appropriate list of values is displayed, and that the user can choose a value from it.
At selection screen on help request:
The event is triggered when the user calls the F1 help for the field <field>. If no corresponding event block has been defined, the help from the ABAP Dictionary is displayed, or none at all if the field has no Dictionary reference. If a corresponding event block exists, it takes precedence over the default help mechanism. It is then up to the programmer to ensure that appropriate help is displayed.
At selection screen on field:
In the PAI event of the selection screen, the event is triggered when the contents of each individual input field are passed from the selection screen to the ABAP program. The input field <field> can be checked in the corresponding event block. If an error message occurs within this event block, the corresponding field is made ready for input again on the selection screen.
At selection screen radio button:
In the PAI event of the selection screen, the event is triggered when the contents of all of the fields in a radio button group are passed from the selection screen to the ABAP program. To define a radio button group <radi>, use the addition RADIOBUTTON GROUP <radi> in the corresponding PARAMETERS statements. This event block allows you to check the whole group. If an error message occurs within this event block, the radio button group is made ready for input again on the selection screen. The individual fields of radio button groups do not trigger the event AT SELECTION-SCREEN ON <field>.
At selection screen on block:
In the PAI event of the selection screen, the event is triggered when the contents of all of the fields in a block are passed from the selection screen to the ABAP program. You define a block by enclosing the declarations of the elements in the block between the statements SELECTION-SCREEN BEGIN OF BLOCK <block> and SELECTION-SCREEN END OF BLOCK <block>. You can use this event block to check the consistency of the input fields in the block. If an error message occurs within this event block, the fields in the block are made ready for input again on the selection screen.
Regards,
Ferry Lianto
‎2007 Nov 23 10:18 PM
Hi,
<b>SELECTION SCREEN</b>
Selection screens are special screens that are defined with the help of ABAP statements. As programmers do not have access to the flow logic of selection screens, they cannot define dialog modules for selection screens. The ABAP runtime environment fully controls the processing flow of selection screens. To allow programmers to modify the selection screen before it is called (PBO) and react to user actions on the selection screen (PAI), the ABAP runtime environment generates a number of special selection screen events before the selection screen is displayed and after the user has executed actions on the selection screen
<b>AT SELECTION-SCREEN OUTPUT</b>
This event is executed at PBO of the selection screen every time the user presses ENTER - in contrast to INITIALIZATION . Therefore, this event is not suitable for setting selection screen default values. Also, since AT SELECTION-SCREEN OUTPUT is first executed after the variant is imported (if a variant is used) and after adopting any values specified under SUBMIT in the WITH clause, changing the report parameters or the selection options in AT SELECTION-SCREEN OUTPUT would destroy the specified values.
Here, however, you can use LOOP AT SCREEN or MODIFY SCREEN to change the input/output attributes of selection screen fields.
<b>Example</b>
SELECT-OPTIONS NAME FOR SY-REPID MODIF ID XYZ.
...
AT SELECTION-SCREEN OUTPUT.
LOOP AT SCREEN.
CHECK SCREEN-GROUP1 = 'XYZ'.
SCREEN-INTENSIFIED = '1'.
MODIFY SCREEN.
ENDLOOP.
<b>AT SELECTION-SCREEN ON VALUE-REQUEST</b>
The event is triggered when the user calls the F4 help for the field field. If no corresponding event block has been defined, no possible values help or values list from the Dictionary is displayed. If a corresponding event block exists, it takes precedence over the default possible values help mechanism. It is then up to the programmer to ensure in the event block that an appropriate list of values is displayed, and that the user can choose a value from it.
No event block AT SELECTION-SCREEN ON VALUE-REQUEST can be created for input fields on the selection screen that are declared within the logical database used. You cannot override the input help mechanism of the logical database within the executable program. You can define separate help within the logical database program using the VALUE-REQUEST option in the PARAMETERS and SELECT-OPTIONSstatements.
<b>Example</b>
INCLUDE DBXYZSEL
...
PARAMETERS PL_TYPE LIKE SAPLANE-PLANETYPE VALUE-REQUEST.
...
REPORT SAPDBXYZ DEFINING DATABASE XYZ.
...
TABLES SAPLANE.
...
FORM PL_TYPE_VAL.
...
CALL FUNCTION ...
...
ENDFORM.
<b>AT SELECTION-SCREEN ON HELP-REQUEST</b>
If the data type of an input field declared in an executable program is defined in the ABAP Dictionary, the documentation of the underlying data element is automatically displayed if the user positions the cursor in that field and presses F1. To create help for input fields that have no Dictionary reference, or to override the help normally linked to the field, you can create an event block for the event
AT SELECTION-SCREEN ON HELP-REQUEST FOR <field>
The event is triggered when the user calls the F1 help for the field <field>. If no corresponding event block has been defined, the help from the ABAP Dictionary is displayed, or none at all if the field has no Dictionary reference. If a corresponding event block exists, it takes precedence over the default help mechanism. It is then up to the programmer to ensure that appropriate help is displayed.
You cannot declare the event block AT SELECTION-SCREEN ON HELP-REQUEST for input fields on the selection screen that are declared within a logical database. You cannot override the help mechanism of a logical database within the program. You can define separate help within the logical database program using the HELP-REQUEST option in the PARAMETERS and SELECT-OPTIONS statements.
REPORT SELECTION_SCREEN_F1_DEMO.
PARAMETERS: P_CARR_1 TYPE S_CARR_ID,
P_CARR_2 TYPE S_CARR_ID.
AT SELECTION-SCREEN ON HELP-REQUEST FOR P_CARR_2.
CALL SCREEN 100 STARTING AT 10 5
ENDING AT 60 10.
This program declares a selection screen with two parameters that both refer to the data element S_CARR_ID in the ABAP Dictionary. The documentation from the ABAP Dictionary is used for P_CARR_1, and a help screen 100 is called for P_CARR_2. The help screen is defined in the Screen Painter as a modal dialog box with next screen 0. It contains the help text defined as help texts. The screen does not require any flow logic.
<b>AT SELECTION-SCREEN ON field</b>
In the PAI event of the selection screen, the event
AT SELECTION-SCREEN ON field
event is triggered. The input field field can be checked in the corresponding event block. If an error message occurs within this event block, the corresponding field is made ready for input again on the selection screen.
<b>Example:</b>
REPORT event_demo.
NODES spfli.
AT SELECTION-SCREEN ON city_fr.
IF carrid-low EQ 'AA' AND city_fr NE 'NEW YORK'.
MESSAGE e010(hb).
ENDIF.
If the user enters AA in the first input field, but not NEW YORK for the departure city, an error message is displayed in the status line until the user enters the correct city.
<b>AT SELECTION-SCREEN ON RADIOBUTTON</b>
In the PAI event of the selection screen, the event
AT SELECTION-SCREEN ON RADIOBUTTON GROUP <radi>
is triggered when the contents of all of the fields in a radio button group are passed from the selection screen to the ABAP program. To define a radio button group <radi>, use the addition RADIOBUTTON GROUP <radi> in the corresponding PARAMETERS statements. This event block allows you to check the whole group. If an error message occurs within this event block, the radio button group is made ready for input again on the selection screen. The individual fields of radio button groups do not trigger the event AT SELECTION-SCREEN ON <field>.
REPORT EVENT_DEMO.
SELECTION-SCREEN BEGIN OF BLOCK B1 WITH FRAME.
PARAMETERS: R1 RADIOBUTTON GROUP RAD1 DEFAULT 'X',
R2 RADIOBUTTON GROUP RAD1,
R3 RADIOBUTTON GROUP RAD1.
SELECTION-SCREEN END OF BLOCK B1.
SELECTION-SCREEN BEGIN OF BLOCK B2 WITH FRAME.
PARAMETERS: R4 RADIOBUTTON GROUP RAD2 DEFAULT 'X',
R5 RADIOBUTTON GROUP RAD2,
R6 RADIOBUTTON GROUP RAD2.
SELECTION-SCREEN END OF BLOCK B2.
AT SELECTION-SCREEN ON RADIOBUTTON GROUP RAD1.
IF R1 = 'X'.
MESSAGE W040(HB).
ENDIF.
AT SELECTION-SCREEN ON RADIOBUTTON GROUP RAD2.
IF R4 = 'X'.
MESSAGE W040(HB).
ENDIF.
If the user does not change one of the radio button groups, a warning is displayed.
<b>AT SELECTION-SCREEN ON BLOCK</b>
In the PAI event of the selection screen, the event
AT SELECTION-SCREEN ON BLOCK <block>
is triggered when the contents of all of the fields in a block are passed from the selection screen to the ABAP program. You define a block by enclosing the declarations of the elements in the block between the statements SELECTION-SCREEN BEGIN OF BLOCK <block> and SELECTION-SCREEN END OF BLOCK <block>. You can use this event block to check the consistency of the input fields in the block. If an error message occurs within this event block, the fields in the block are made ready for input again on the selection screen.
Regards,
Maha
‎2007 Nov 24 2:09 AM
Different Types of Selection Screens
What is:
1. at selection-screen on field
2. at selection-screen output
3. at selection-screen block
4. at selection-screen on value-request
5. at selection-screen on help-request and their difference?
For knowing Selection-screens:
First you must have right understanding of Events.
- Events are introduced by Event Keyword. They end when again next processs begins.
Selection-screens are special screen defined in ABAP.
- This ABAP at run time only controls the flow logic of Selection-screens. The PBO and PAI triggers the num of. selection-screens.
The basic form of the selection screen events is the AT SELECTION-SCREEN event. This event occurs after the runtime environment has passed all input data from the selection screen to the ABAP program. The other selection screen events allow programmers to modify the selection screen before it is sent and specifically check user input.
"At Selection-screen OUTPUT is trigerred in PBO of selection-screen.
- This allows you to modify the Selection-screen, before it is displayed.
"At Selection-screen On Field is triggered in PAI of selection-screens.
- The input fields can b checked,in the corresponding event block. If an error message occurs within this event block, the corresponding field is made ready for input again on the selection screen.
"At Selection-screen On Block is trigerred in PAI event.
- You define a block by enclosing the declarations of the elements in the block between the statements SELECTION-SCREEN BEGIN OF BLOCK block - END OF BLOCK block. You can use this event block to check the consistency of the input fields in the block.
"At Selection-screen On value request.
- This event is trigerred for F4 help.
"At Selection-screen On help request .
- This event is triggered when the user clicks F1 for help on fileds.
Reward points if it is usefull.....
Girish
‎2007 Nov 24 2:40 PM
HI,
with this link you will get complete idea about the at selection screen events
http://help.sap.com/saphelp_nw04/helpdata/en/56/1eb6c705ad11d2952f0000e8353423/content.htm
AT selection0-screen on filed
This events will be triggered if you do some action on perticular field mentioned in the field option
at selection-screen output
when ever you do any action on the screen then this event wuill trigger
if you click on the field mentioned in the field option then at selection-screen on field will trigger 1st
if you press any button or enter button then at selection-screen output will trigger
http://help.sap.com/saphelp_nw2004s/helpdata/en/79/34a237d9b511d1950e0000e8353423/content.htm
http://www.sap-img.com/abap/different-types-of-selection-screens.htm
‎2007 Nov 24 5:07 PM
Hi Akash,
At selection-screen is the event of a report program in which we have to validate the selection screen fields.
At selection-screen output is the event in reports in which we have to do selection screen modifications.
At selection-screen on value request is the event in reports in which we have to write the code for the f4 help. When the user presses f4 key this event is triggered.
At selection-screen on help request is the event in reports. In this block we write code to the f1 help. This event is triggered when user presses f1 key.
At selection-screen on field is event of a report in which we have validate a single field. If an error occurs the field is input enabled.
At selection-screen on radiobutton group rad1 is the event of a report in which we have to validate the radiobuttons of that group rad1. If error occurs that group is input enabled.
At selection-screen on block b1 is the event of a report in which we have to validate all the fields in that block. If an error occurs in any of field all the fields are input enabled in that block.
regards,
kamala.
‎2007 Nov 26 11:51 AM
hi,
At selection screen -
> Display Button and Text and Label.
At selection screen output----> Enable / Disable.
At selection screen- on value request----> F4 is assigned by value.
At selection screen-on help request---->F1 is displayed tutorials.
At selection screen-on field---> it is used for PAI.
At selection screen- radio button----> group by radio ( any value same as another value).
At selection screen on block---> it is displayed in Frame and Textbox.
Warm Regards,
S.Suresh.
Reward if useful...