ABAP/4   ОКМ   ДМ   экономическая информатика   4GL   Теория и практика обработки информации

Компьютерный язык ABAP/4 - ключевые слова

RECEIVE

Basic form

RECEIVE RESULTS FROM FUNCTION func.

Additions



1. ... IMPORTING p1 = f1 ... pn = fn
2. ... TABLES p1 = itab1 ... pn = itabn
3. ... EXCEPTIONS except1 = rc1 ... exceptn = rcn

Effect

Used within a FORM routine to receive the results of an asynchronous function module call (CALL FUNCTION func STARTING NEW TASK task name ) as IMPORTING or TABLES parameters. In addition, the FORM routine must have a placeholder to receive the task name (e.g. when you use USING task name ). See example below.

Notes

This key word occurs only with the function module call CALL FUNCTION func STARTING NEW TASK task name . If the function module returns no results, this part need not be defined.

This key word is new from Release 3.0. Therefore, both partner systems (client and server) must have Release 3.0 of the R/3 System.

Addition 1

... IMPORTING p1 = f1 ... pn = fn

Effect

IMPORTING returns the values of fields and field strings from the function module to the calling program. In the function module, the formal parameters are defined as export parameters. You can pass any number of export parameters.

Addition 2

... TABLES p1 = itab1 ... pn = itabn

Effect

The TABLES statement contains references to internal tables. All table parameters of the function module must be covered.

Addition 3

... EXCEPTIONS except1 = rc1 ... exceptn = rcn

Effect

Under EXCEPTIONS , you execute the exceptions handled by the calling program itself. At the end of the exception list, you can use OTHERS to refer to all remaining exceptions.
If one of the listed exceptions occurs, SY-SUBRC is set to the assigned value rc (number literal!) and control passes to the calling program. By specifying a return code, you can group exceptions into classes. With the second form, without " = rc ", SY-SUBRC is set to a value other than 0 if an exception occurs.
If the function module triggers an exception (RAISE and MESSAGE ... RAISING ) not meant to be handled by the program itself,

Note

The following EXCEPIONS are predefined by the system and have a special meaning:

Example

DATA: INFO LIKE RFCSI, * Result of RFC_SYSTEM_INFO function SYSTEM_MSG(80) VALUE SPACE. * Exception handling CALL FUNCTION 'RFC_SYSTEM_INFO' STARTING NEW TASK 'INFO' PERFORMING 'RETURN_INFO' ON END OF TASK. WRITE: 'Wait for reply'. ... AT USER-COMMAND. * Return from FORM routine RETURN_INFO IF SYSTEM_MSG = SPACE. WRITE: 'Destination =', INFO-RFCDEST. ELSE. WRITE SYSTEM_MSG. ENDIF. ... FORM RETURN_INFO USING TASKNAME. RECEIVE RESULTS FROM FUNCTION 'RFC_SYSTEM_INFO' IMPORTING RFCSI_EXPORT = INFO EXCEPTIONS SYSTEM_FAILURE MESSAGE SYSTEM_MSG. REFRESH SCREEN. "Simulate command field = return key ENDFORM.

RECEIVE_ILLEGAL_SWITCH

Index
© SAP AG 1996
ABAP/4   ОКМ   ДМ   экономическая информатика   4GL   Теория и практика обработки информации

НОВОСТИ ФОРУМА

Форум Рыцари теории эфира


Рыцари теории эфира
 10.11.2021 - 12:37: ПЕРСОНАЛИИ - Personalias -> WHO IS WHO - КТО ЕСТЬ КТО - Карим_Хайдаров.
10.11.2021 - 12:36: СОВЕСТЬ - Conscience -> РАСЧЕЛОВЕЧИВАНИЕ ЧЕЛОВЕКА. КОМУ ЭТО НАДО? - Карим_Хайдаров.
10.11.2021 - 12:36: ВОСПИТАНИЕ, ПРОСВЕЩЕНИЕ, ОБРАЗОВАНИЕ - Upbringing, Inlightening, Education -> Просвещение от д.м.н. Александра Алексеевича Редько - Карим_Хайдаров.
10.11.2021 - 12:35: ЭКОЛОГИЯ - Ecology -> Биологическая безопасность населения - Карим_Хайдаров.
10.11.2021 - 12:34: ВОЙНА, ПОЛИТИКА И НАУКА - War, Politics and Science -> Проблема государственного терроризма - Карим_Хайдаров.
10.11.2021 - 12:34: ВОЙНА, ПОЛИТИКА И НАУКА - War, Politics and Science -> ПРАВОСУДИЯ.НЕТ - Карим_Хайдаров.
10.11.2021 - 12:34: ВОСПИТАНИЕ, ПРОСВЕЩЕНИЕ, ОБРАЗОВАНИЕ - Upbringing, Inlightening, Education -> Просвещение от Вадима Глогера, США - Карим_Хайдаров.
10.11.2021 - 09:18: НОВЫЕ ТЕХНОЛОГИИ - New Technologies -> Волновая генетика Петра Гаряева, 5G-контроль и управление - Карим_Хайдаров.
10.11.2021 - 09:18: ЭКОЛОГИЯ - Ecology -> ЭКОЛОГИЯ ДЛЯ ВСЕХ - Карим_Хайдаров.
10.11.2021 - 09:16: ЭКОЛОГИЯ - Ecology -> ПРОБЛЕМЫ МЕДИЦИНЫ - Карим_Хайдаров.
10.11.2021 - 09:15: ВОСПИТАНИЕ, ПРОСВЕЩЕНИЕ, ОБРАЗОВАНИЕ - Upbringing, Inlightening, Education -> Просвещение от Екатерины Коваленко - Карим_Хайдаров.
10.11.2021 - 09:13: ВОСПИТАНИЕ, ПРОСВЕЩЕНИЕ, ОБРАЗОВАНИЕ - Upbringing, Inlightening, Education -> Просвещение от Вильгельма Варкентина - Карим_Хайдаров.
Bourabai Research - Технологии XXI века Bourabai Research Institution