SAP Function Modules

LXVAS_REF_DOC_BY_VAS_ORDER_GET SAP Function module - Get reference document details for VAS Order







LXVAS_REF_DOC_BY_VAS_ORDER_GET is a standard SAP function module available within R/3 SAP systems depending on your version and release level. Below is the pattern details for this FM showing its interface including any import and export parameters, exceptions etc as well as any documentation contributions (Comments) specific to the object.

See here to view full function module documentation and code listing, simply by entering the name LXVAS_REF_DOC_BY_VAS_ORDER_GET into the relevant SAP transaction such as SE37 or SE80.

Associated Function Group: LXVAS_CREOR
Released Date: Not Released
Processing type: Normal fucntion module
Normal function module settings


Pattern for FM LXVAS_REF_DOC_BY_VAS_ORDER_GET - LXVAS REF DOC BY VAS ORDER GET





CALL FUNCTION 'LXVAS_REF_DOC_BY_VAS_ORDER_GET' "Get reference document details for VAS Order
  EXPORTING
    iv_warehouse =              " leint_lgnum   Warehouse Number
    iv_vas_order_id =           " lxvas_vorid   VAS Order
*   is_header_only =            " flag          General Flag
  IMPORTING
    es_ldocv =                  " lxhme_ldocv   Logistic document view
    es_ref_doc =                " lxhme_refdc   Document reference
  EXCEPTIONS
    NO_VAS_ORDER_FOUND = 1      "               No VAS Order found
    NO_VAS_ORDER_REQUEST_FOUND = 2  "           No VAS Order request found
    .  "  LXVAS_REF_DOC_BY_VAS_ORDER_GET

ABAP code example for Function Module LXVAS_REF_DOC_BY_VAS_ORDER_GET





The ABAP code below is a full code listing to execute function module LXVAS_REF_DOC_BY_VAS_ORDER_GET including all data declarations. The code uses the latest in-line data DECLARATION SYNTAX but I have included an ABAP code snippet at the end to show how declarations would look using the original method of declaring data variables up front. This will allow you to compare and fully understand the new inline method. Please note some of the newer syntax such as the @DATA is not available until a later 4.70 service pack (SP8).

DATA:
ld_es_ldocv  TYPE LXHME_LDOCV ,
ld_es_ref_doc  TYPE LXHME_REFDC .

DATA(ld_iv_warehouse) = 'Check type of data required'.
DATA(ld_iv_vas_order_id) = 'Check type of data required'.
DATA(ld_is_header_only) = 'Check type of data required'. . CALL FUNCTION 'LXVAS_REF_DOC_BY_VAS_ORDER_GET' EXPORTING iv_warehouse = ld_iv_warehouse iv_vas_order_id = ld_iv_vas_order_id * is_header_only = ld_is_header_only IMPORTING es_ldocv = ld_es_ldocv es_ref_doc = ld_es_ref_doc EXCEPTIONS NO_VAS_ORDER_FOUND = 1 NO_VAS_ORDER_REQUEST_FOUND = 2 . " LXVAS_REF_DOC_BY_VAS_ORDER_GET
IF SY-SUBRC EQ 0. "All OK ELSEIF SY-SUBRC EQ 1. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 2. "Exception "Add code for exception here ENDIF.







ABAP code to compare 7.40 inline data declaration with original syntax

The below ABAP code uses the older none in-line data declarations. This allows you to see the coding differences/benefits of the later inline syntax. It may also be useful if you are using an older version of SAP as some of the newer syntax above, such as the @DATA is not available until 4.70 EHP 8.

DATA:
ld_es_ldocv  TYPE LXHME_LDOCV ,
ld_iv_warehouse  TYPE LEINT_LGNUM ,
ld_es_ref_doc  TYPE LXHME_REFDC ,
ld_iv_vas_order_id  TYPE LXVAS_VORID ,
ld_is_header_only  TYPE FLAG .

ld_iv_warehouse = 'Check type of data required'.
ld_iv_vas_order_id = 'Check type of data required'.
ld_is_header_only = 'Check type of data required'.

Contribute (Add Comments)

Please help keep this info upto date and use the comments section below to add useful hints, tips and information specific to this SAP function. This will then be available for you and other users to easily find by simply searching on the object name LXVAS_REF_DOC_BY_VAS_ORDER_GET or its description.