SAP FSH_VAS_SD_DOC_DATA Function Module for VAS data in SD document
FSH_VAS_SD_DOC_DATA is a standard fsh vas sd doc data SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for VAS data in SD document 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 fsh vas sd doc data FM, simply by entering the name FSH_VAS_SD_DOC_DATA into the relevant SAP transaction such as SE37 or SE38.
Function Group: FSH_VAS
Program Name: SAPLFSH_VAS
Main Program: SAPLFSH_VAS
Appliation area:
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:

Function FSH_VAS_SD_DOC_DATA 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 'FSH_VAS_SD_DOC_DATA'"VAS data in SD document.
EXPORTING
* IS_VBAK = "Sales Document: Header Data
* IV_SOLD_TO_PARTY = "Sold to party
* IV_SHIP_TO_PARTY = "Ship to Party
* IT_XVBAP = "Table Type for VBAP structure
* IT_XVBEP = "Table Type for XVBEP/YVBEP
* IV_VAS_PLANT_CHECK = "Enable VAS Plant Capability Check
IMPORTING Parameters details for FSH_VAS_SD_DOC_DATA
IS_VBAK - Sales Document: Header Data
Data type: VBAKOptional: Yes
Call by Reference: No ( called with pass by value option)
IV_SOLD_TO_PARTY - Sold to party
Data type: KUNNROptional: Yes
Call by Reference: No ( called with pass by value option)
IV_SHIP_TO_PARTY - Ship to Party
Data type: KUNNROptional: Yes
Call by Reference: No ( called with pass by value option)
IT_XVBAP - Table Type for VBAP structure
Data type: FSH_SD_VBAP_TTOptional: Yes
Call by Reference: No ( called with pass by value option)
IT_XVBEP - Table Type for XVBEP/YVBEP
Data type: TAB_XYVBEPOptional: Yes
Call by Reference: No ( called with pass by value option)
IV_VAS_PLANT_CHECK - Enable VAS Plant Capability Check
Data type: RFM_VAS_PLANT_CHECKOptional: Yes
Call by Reference: No ( called with pass by value option)
Copy and paste ABAP code example for FSH_VAS_SD_DOC_DATA 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_is_vbak | TYPE VBAK, " | |||
| lv_iv_sold_to_party | TYPE KUNNR, " | |||
| lv_iv_ship_to_party | TYPE KUNNR, " | |||
| lv_it_xvbap | TYPE FSH_SD_VBAP_TT, " | |||
| lv_it_xvbep | TYPE TAB_XYVBEP, " | |||
| lv_iv_vas_plant_check | TYPE RFM_VAS_PLANT_CHECK. " |
|   CALL FUNCTION 'FSH_VAS_SD_DOC_DATA' "VAS data in SD document |
| EXPORTING | ||
| IS_VBAK | = lv_is_vbak | |
| IV_SOLD_TO_PARTY | = lv_iv_sold_to_party | |
| IV_SHIP_TO_PARTY | = lv_iv_ship_to_party | |
| IT_XVBAP | = lv_it_xvbap | |
| IT_XVBEP | = lv_it_xvbep | |
| IV_VAS_PLANT_CHECK | = lv_iv_vas_plant_check | |
| . " FSH_VAS_SD_DOC_DATA | ||
ABAP code using 7.40 inline data declarations to call FM FSH_VAS_SD_DOC_DATA
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