SAP SELECTION-SCREEN MODIF ID ABAP Statements

Get Example source ABAP code based on a different SAP table
  



SELECTION-SCREEN - MODIF ID

Short Reference
• MODIF ID SELECTION-SCREEN


ABAP Syntax ... MODIF ID modid ... .


What does it do? After the MODIF ID addition, a modid identifier can be specified to assign a screen element of a selection screen to a modification group. The MODIF ID addition can be specified for the following statements: SELECTION-SCREEN - COMMENT SELECTION-SCREEN - PUSHBUTTON SELECTION-SCREEN - TAB SELECTION-SCREEN - ULINE PARAMETERS SELECT-OPTIONS

The name of the modid modification group must be specified directly and must have no more than three characters. When generating a selection screen, modid is entered (for the properties of the screen elements created using the above statement) in the group which is assigned to the component group1 of the structure SCREEN. All screen elements of a group can be modified before displaying the selection screen together with the MODIFY SCREEN statement. Note

Note

The modification groups which are assigned to the group2 and group3 columns of the structure SCREEN, are set by the system when generating a selection screen. group2 contains the value 'DBS' for screen elements which are defined in a logical database. group3 can contain values from the following table. group4 is only intended for internal use.

Possible values in group3: KeyMeaning of the screen element BLKFrame or title of a block COFOutput field that uses the FOR FIELD addition to link to a parameter or selection criterion. COMOutput field that is not linked to a parameter or a selection criterion. HGHInput field for the upper interval limit of a selection criterion ISXInput field for a parameter that is linked to a search help using the AS SEARCH PATTERN addition. LOWInput field for the lower interval limit of a selection criterion OPUIcon for the selection options of a selection criterion PARInput field of a parameter PBUPushbutton TABTab title TOTOutput field for text before the input field of the upper interval limit of a selection criterion TSTTabstrip TXTOutput field for text before the input field of a parameter or the lower interval limit of a selection criteria ULIHorizontal line VPUPushbutton for multiple selection of a selection criterion



Example ABAP Coding
The elements of the b2 block are assigned to the
bl2 modification group. The show_all checkbox enables the option of displaying these elements. The change in the display takes place immediately, since the AT SELECTION-SCREEN event is triggered when the checkbox is selected. The function code is not needed. Instead, the content of show_all is evaluated at PBO. PARAMETERS show_all AS CHECKBOX USER-COMMAND flag.

SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME.
PARAMETERS: p1 TYPE c LENGTH 10,
p2 TYPE c LENGTH 10,
p3 TYPE c LENGTH 10.
SELECTION-SCREEN END OF BLOCK b1.

SELECTION-SCREEN BEGIN OF BLOCK b2 WITH FRAME.
PARAMETERS: p4 TYPE c LENGTH 10 MODIF ID bl2,
p5 TYPE c LENGTH 10 MODIF ID bl2,
p6 TYPE c LENGTH 10 MODIF ID bl2.
SELECTION-SCREEN END OF BLOCK b2.

AT SELECTION-SCREEN OUTPUT.
LOOP AT SCREEN INTO DATA(screen_wa).
IF show_all <(><<)>> 'X' AND
screen_wa-group1 = 'BL2'.
screen_wa-active = '0'.
ENDIF.
MODIFY SCREEN FROM screen_wa.
ENDLOOP.

Return to menu