SAP DPSPP_RFC_DOC_LOAD_FROM_REF Function Module for Dealer Portal Spare Parts: Load new Order from Reference
DPSPP_RFC_DOC_LOAD_FROM_REF is a standard dpspp rfc doc load from ref SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for Dealer Portal Spare Parts: Load new Order from Reference processing and below is the pattern details for this FM, showing its interface including any import and export parameters, exceptions etc. there is also a full "cut and paste" ABAP pattern code example, along with implementation ABAP coding, documentation and contribution comments specific to this or related objects.
See here to view full function module documentation and code listing for dpspp rfc doc load from ref FM, simply by entering the name DPSPP_RFC_DOC_LOAD_FROM_REF into the relevant SAP transaction such as SE37 or SE38.
Function Group: DP_SPP_RFC
Program Name: SAPLDP_SPP_RFC
Main Program: SAPLDP_SPP_RFC
Appliation area:
Release date: N/A
Mode(Normal, Remote etc): Remote-Enabled
Update:

Function DPSPP_RFC_DOC_LOAD_FROM_REF pattern details
In-order to call this FM within your sap programs, simply using the below ABAP pattern details to trigger the function call...or see the full ABAP code listing at the end of this article. You can simply cut and paste this code into your ABAP progrom as it is, including variable declarations.CALL FUNCTION 'DPSPP_RFC_DOC_LOAD_FROM_REF'"Dealer Portal Spare Parts: Load new Order from Reference.
EXPORTING
IV_AUART = "Sales Document Type
IV_VKORG = "Sales Organization
IV_VTWEG = "Distribution Channel
IV_SPART = "Division
IV_KUNNR = "Customer Number 1
IV_VBELN_REF = "Sales Document
IMPORTING
ET_MESSAGE = "Return parameter table
ES_HEAD_COM = "Lean Order - Header Data
ET_ITEM_COM = "Dealer Portal Spare Parts: Table type for TDS_ITEM_COM
ET_PARTY_COM = "Dealer Portal Spare Parts: Table type for TDS_PARTY_COM
ET_SLINE_COM = "Dealer Portal Spare Parts: Table type for TDS_SLINE_COM
ET_COND_COM = "Dealer Portal Spare Parts: Table type for TDS_COND_COM
ET_HEAD_TEXT_COM = "Dealer Portal Spare Parts: Table type for TDS_TEXT_COM
ET_ITEM_TEXT_COM = "Dealer Portal Spare Parts: Table type for TDS_TEXT_COM
IMPORTING Parameters details for DPSPP_RFC_DOC_LOAD_FROM_REF
IV_AUART - Sales Document Type
Data type: AUARTOptional: No
Call by Reference: No ( called with pass by value option)
IV_VKORG - Sales Organization
Data type: VKORGOptional: No
Call by Reference: No ( called with pass by value option)
IV_VTWEG - Distribution Channel
Data type: VTWEGOptional: No
Call by Reference: No ( called with pass by value option)
IV_SPART - Division
Data type: SPARTOptional: No
Call by Reference: No ( called with pass by value option)
IV_KUNNR - Customer Number 1
Data type: KUNNROptional: No
Call by Reference: No ( called with pass by value option)
IV_VBELN_REF - Sales Document
Data type: VBELN_VAOptional: No
Call by Reference: No ( called with pass by value option)
EXPORTING Parameters details for DPSPP_RFC_DOC_LOAD_FROM_REF
ET_MESSAGE - Return parameter table
Data type: BAPIRET2_TOptional: No
Call by Reference: No ( called with pass by value option)
ES_HEAD_COM - Lean Order - Header Data
Data type: TDS_HEAD_COMOptional: No
Call by Reference: No ( called with pass by value option)
ET_ITEM_COM - Dealer Portal Spare Parts: Table type for TDS_ITEM_COM
Data type: DPSPPT_ITEM_COMOptional: No
Call by Reference: No ( called with pass by value option)
ET_PARTY_COM - Dealer Portal Spare Parts: Table type for TDS_PARTY_COM
Data type: DPSPPT_PARTY_COMOptional: No
Call by Reference: No ( called with pass by value option)
ET_SLINE_COM - Dealer Portal Spare Parts: Table type for TDS_SLINE_COM
Data type: DPSPPT_SLINE_COMOptional: No
Call by Reference: No ( called with pass by value option)
ET_COND_COM - Dealer Portal Spare Parts: Table type for TDS_COND_COM
Data type: DPSPPT_COND_COMOptional: No
Call by Reference: No ( called with pass by value option)
ET_HEAD_TEXT_COM - Dealer Portal Spare Parts: Table type for TDS_TEXT_COM
Data type: DPSPPT_TEXT_COMOptional: No
Call by Reference: No ( called with pass by value option)
ET_ITEM_TEXT_COM - Dealer Portal Spare Parts: Table type for TDS_TEXT_COM
Data type: DPSPPT_TEXT_COMOptional: No
Call by Reference: No ( called with pass by value option)
Copy and paste ABAP code example for DPSPP_RFC_DOC_LOAD_FROM_REF Function Module
The ABAP code below is a full code listing to execute function module POPUP_TO_CONFIRM including all data declarations. The code uses the original data declarations rather than 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 newer method of declaring data variables on the fly. 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), which i why i have stuck to the origianl for this example.| DATA: | ||||
| lv_iv_auart | TYPE AUART, " | |||
| lv_et_message | TYPE BAPIRET2_T, " | |||
| lv_iv_vkorg | TYPE VKORG, " | |||
| lv_es_head_com | TYPE TDS_HEAD_COM, " | |||
| lv_iv_vtweg | TYPE VTWEG, " | |||
| lv_et_item_com | TYPE DPSPPT_ITEM_COM, " | |||
| lv_iv_spart | TYPE SPART, " | |||
| lv_et_party_com | TYPE DPSPPT_PARTY_COM, " | |||
| lv_iv_kunnr | TYPE KUNNR, " | |||
| lv_et_sline_com | TYPE DPSPPT_SLINE_COM, " | |||
| lv_et_cond_com | TYPE DPSPPT_COND_COM, " | |||
| lv_iv_vbeln_ref | TYPE VBELN_VA, " | |||
| lv_et_head_text_com | TYPE DPSPPT_TEXT_COM, " | |||
| lv_et_item_text_com | TYPE DPSPPT_TEXT_COM. " |
|   CALL FUNCTION 'DPSPP_RFC_DOC_LOAD_FROM_REF' "Dealer Portal Spare Parts: Load new Order from Reference |
| EXPORTING | ||
| IV_AUART | = lv_iv_auart | |
| IV_VKORG | = lv_iv_vkorg | |
| IV_VTWEG | = lv_iv_vtweg | |
| IV_SPART | = lv_iv_spart | |
| IV_KUNNR | = lv_iv_kunnr | |
| IV_VBELN_REF | = lv_iv_vbeln_ref | |
| IMPORTING | ||
| ET_MESSAGE | = lv_et_message | |
| ES_HEAD_COM | = lv_es_head_com | |
| ET_ITEM_COM | = lv_et_item_com | |
| ET_PARTY_COM | = lv_et_party_com | |
| ET_SLINE_COM | = lv_et_sline_com | |
| ET_COND_COM | = lv_et_cond_com | |
| ET_HEAD_TEXT_COM | = lv_et_head_text_com | |
| ET_ITEM_TEXT_COM | = lv_et_item_text_com | |
| . " DPSPP_RFC_DOC_LOAD_FROM_REF | ||
ABAP code using 7.40 inline data declarations to call FM DPSPP_RFC_DOC_LOAD_FROM_REF
The below ABAP code uses the newer in-line data declarations. This allows you to see the coding differences/benefits of the later inline syntax. Please note some of the newer syntax below, such as the @DATA is not available until 4.70 EHP 8.Search for further information about these or an SAP related objects