Show TOC

Input Help on the DynproLocate this document in the navigation structure

Use

Within Screen Painter, two types of input help can be defined on the dynpro:

  1. The FIELD statement with one of the additions VALUES or SELECT.

  2. Binding a search help directly to a dynpro field.

If a search help is bound directly to a dynpro field, it overrides the additions of the FIELD statement. However, the input check functions of the FIELD statement remain unaffected.

Input Help in Flow Logic

The following input help methods are obsolete and should not be used. They are still supported for compatibility reasons.

In the flow logic, a value list can be specified for a dynpro field f as follows:

FIELD f VALUES ( val 1 , val 2 ,...).

The value list should be defined using a series of single values val 1 , val 2 ,.... The NOT and BETWEEN additions for the input check are not appropriate for input helps.

A value list can also be created by accessing a database table as follows:



FIELD f SELECT   * 
          FROM  dbtab 
          WHERE k1 = f1 AND k2 = f2 AND...




            

In the WHERE condition, the fields of the primary key k 1 , k 2 ... of the database table dbtab are checked against the dynpro fields f 1 , f 2 ... . The WHENEVER addition, used with input checks, is not necessary for input helps.

If a ABAP Dictionary reference is used for field f, the selection and the hit list formatting may be affected by any check table attached to the field.

Binding a Search Help

Search helps from ABAP Dictionary can be bound to a dynpro field. To do this, the name of the search help must be entered in the Search Help field in the attributes of the screen field in Screen Painter. This assigns the first parameter of the search help to the dynpro field. As a result, it is only possible to return one value from the hit list to the screen template.

Input help on a dynpro.





REPORT demo_dynpro_f4_help_dynpro MESSAGE-ID dw.
DATA: carrier(3) TYPE c,
      connection(4) TYPE c.
CALL SCREEN 100.
MODULE cancel INPUT.
  LEAVE PROGRAM.
ENDMODULE.


            

The static next dynpro number of dynpro 100 is 100. It has the following layout:

The input fields are applied from the program fields carrier and connection. The function code of the pushbutton is CANCEL, with function type E. The search help DEMO_F4_DE with the search help parameter CARRID is assigned to the dynpro field carrier. The search help uses the database table SCARR.

The screen flow logic is as follows:





PROCESS BEFORE OUTPUT.
PROCESS AFTER INPUT.
  MODULE cancel AT EXIT-COMMAND.
  FIELD carrier VALUES ('AA', 'LH').
  FIELD connection SELECT *
                      FROM  spfli
                      WHERE carrid = carrier 
                        AND connid = connection.


            

When the user chooses input help for the individual fields, the following is displayed:

  • For the Airline field, the search help displays the names of the airlines and places the airline code in the input field for the chosen line. If the airline code is not one of those listed in the VALUES list of the flow logic, the input check triggers an error message in the PAI event. The search help, therefore, overrides the VALUES addition for the input help, but not for the input checks. This is therefore not an appropriate place to use the VALUE S addition.

  • For the Flight Number field, the flow logic displays the selected entries from the database table SPFLI and places the selected line in the input field.