Input Checks
You can use the AT SELECTION-SCREEN ON BLOCK <block> event to check the entry combinations of a logical group. All fields in this block become ready for input when an error message is displayed.
The AT SELECTION-SCREEN ON END OF event is triggered after the selection table has been fully passed to the program after a user action in the dialog box for the multiple selection has taken place. The entire selection table can be checked in this event block.
You can perform input checks for the selection criteria of a logical database that you use and for your own program-specific selections.
Field Help and Input Help
You can program your own F1 help (field help) and F4 help (input help) using the AT SELECTION-SCREEN ON HELP-REQUEST and AT SELECTION-SCREEN ON VALUE-REQUEST events.
F1 help can refer to individual parameters or a selection table (SELECT-OPTION). If you specify the name of a SELECT-OPTIONS table, the help is available for both seltab-low and seltab-high. You must specify the lower interval field or the upper interval field as a reference for F4 help, for a selection option.
When a user positions the cursor in a field and uses the F1 or F4 function key, the system triggers the appropriate event.
The addition of ON VALUE-REQUEST displays the button for F4 help for the corresponding field.
Hint: F1 and F4 help are usually stored in the ABAP Dictionary. This has the advantage that the programmer does not need to deal with the actual data retrieval for the input help, or the transfer of the selected value to the input field. For the user, F1 and F4 help of this type provide a uniform, cross-program design.
Selection Screen − Variants
A user can create any number of selection screen variants for a program. Variants are uniquely assigned to one program, and are not available in other programs.
Creating variants is useful when you frequently start a program with the same selections or run the program in the background.
If you choose Start using variant in the program attributes, then users must specify a variant when executing the program.
If the program uses several selection screens, a variant can be created for all selection screens, or individually for each selection screen.
Selection Screen Attributes
Assign a name and a description to each variant. By default, variants are available for both dialog and background processing. You can also define a variant exclusively for use with background processing.
You can prevent other users from making changes to your variant. If you select Only display in catalog, this variant is displayed only in the catalog, but not in the general value help (F4).
The variant catalog is part of the ABAP Workbench and it is only accessible to ABAP developers. It is not available to the normal users of a program. To call the variants catalog (an overview of all existing variants), starting from the ABAP Editor, choose Goto->Variants and then Variants->Catalog.
The type of a selection is defined in its declaration, for example, type S for SELECT-OPTIONS, type P for PARAMETERS. If you choose ->Selections protected, the fields are not ready for input. You use the ->Hide attribute to hide selections that are not required, making the selection screen clearer.