Show TOC

Background documentationInput Help on the Dynpro Locate this document in the navigation structure

 

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 (val1, val2,...).

The value list should be defined using a series of single values val1, val2,.... 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:

Syntax Syntax

  1. FIELD f SELECT   * 
  2.           FROM  dbtab 
  3.           WHERE k1 = f1 AND k2 = f2 AND...
End of the code.

In the WHERE condition, the fields of the primary key k1, k2 ... of the database table dbtab are checked against the dynpro fields f1 , f2 ... . 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.

Syntax Syntax

Input help on a dynpro.

  1. REPORT demo_dynpro_f4_help_dynpro MESSAGE-ID dw.
  2. DATA: carrier(3) TYPE c,
  3.       connection(4) TYPE c.
  4. CALL SCREEN 100.
  5. MODULE cancel INPUT.
  6.   LEAVE PROGRAM.
  7. ENDMODULE.
End of the code.

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

This graphic is explained in the accompanying text.

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.

Syntax Syntax

The screen flow logic is as follows:

  1. PROCESS BEFORE OUTPUT.
  2. PROCESS AFTER INPUT.
  3.   MODULE cancel AT EXIT-COMMAND.
  4.   FIELD carrier VALUES ('AA', 'LH').
  5.   FIELD connection SELECT *
  6.                       FROM  spfli
  7.                       WHERE carrid = carrier 
  8.                         AND connid = connection.
End of the code.

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 VALUES 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.