ABAP Dictionary Search Help

Use

In Web Dynpro ABAP, you can reuse existing search helps from the ABAP Dictionary.

In your view you can create input help (F4 help) for fields, which makes it easier for users to input data.

There are two types of search help:

  • Elementary search helps

  • Collective search help

Integration

ABAP Dictionary search helps are integrated into a Web Dynpro application by means of the Value Help Mode property of the context attributes. More information: Creating and Maintaining Context Attributes.

Only the Automatic and Dictionary Structure options are relevant for ABAP Dictionary search helps:

  • Automatically

    The search help assigned to the data type of the context attribute in the ABAP Dictionary is used. The search help is displayed under Determined Search Help and cannot be changed.

    If no search help can be determined for the attribute type, no search help symbol is displayed and no search help can be performed.

  • Dictionary structure

    One search help from the Dictionary can be assigned to the context attribute. Beneath the Input Help Mode field, the Dictionary Structure field appears, in which you can enter the search help you want. The search help must be defined in the ABAP Dictionary. If you do not enter a search help, at runtime the system attempts to determine a search help using the type of context attribute.

Input Help for Date Fields

The standard value for the first day of the week is Monday. You can define a different day with BAdI CALENDAR_DEFINITION, whereby the display of the week days and calculation of the week number changes:

The value help for date fields (function module F4_DATE from function group SHLC) calls the BAdI above. The display is changed in the F4 help so that the first day of the week is the one from the BAdI implementation. If a week number is used that deviates from the ISO rule, F4 help hides this since the front-end control used does not support deviant week counts.

More information: SAP Note 1063178 Information published on SAP site.

Value Help and the onEnter Event

Often it is preferable that the onEnter action handler of InputFields is executed directly after a value has been selected from the value help in order to, for example, update view fields that are dependent on this InputField. This setting can be made for DDIC value help for each view separately by calling method register_on_enter_for_f4() of interface IF_WD_VIEW_CONTROLLER. For other value help (OVS and user-programmed value help), the entry value processing must be handled by the application itself.

          
METHOD wddoinit.
          
wd_this->wd_get_api( )->register_on_enter_for_f4( register_on_enter = abap_true ).
          
ENDMETHOD.
            

Restrictions

  • The hot key for collective search helps is not supported.

  • When reusing ABAP Dictionary search helps, there may be situations in which you want a search help exit in the Web Dynpro environment to behave differently to one in the classic Dynpro environment. For example, in the Web Dynpro environment it is not possible to process a separate dialog using a CALL SCREEN.

    An application can find out whether it is running in the Web Dynpro environment by querying the IS_ACTIVE attribute of the CL_WEB_DYNRPO class:

                  
    IF CL_WEB_DYNPRO=>is_active = abap_true. ... ELSE. ... ENDIF.
                      
  • There is no automatic F4 help for data element TIMS.

  • The date value help in Web Dynpro ABAP does not support all ABAP date formats, see also 1056623 Information published on SAP site.

  • In certain cases, no personal value list is available. This can occur if the personal value help function was explicitly deactivated using the search help exit. To provide a uniform display, the tab page for personal value help is still shown in the UI, but the user cannot select it. The same is true for the button for copying values to the personal value help.

  • If you restrict the selection so that an InputField is readOnly, only filtered values that match this restriction will be displayed in the suggested values list of dependent .InputFields.

Example

You can find an example of the ABAP Dictionary search help in the system in component WDR_TEST_DDIC_SHLP.