Ansicht
Dokumentation
SRM_DOCUMENT_CHECKOUT_VIA_FILE - SRM: Get Document Content with File Transfer
CPI1466 during Backup RFUMSV00 - Advance Return for Tax on Sales/PurchasesThis documentation is copyright by SAP AG.
Functionality
Downloads the document to the desktop in local files
In most cases, a document consists of a single file. If there is more than one file, you can use the function module SRM_DOCUMENT_GET_COMP_INFO to determine the components of the document.
Example
DATA:
objectid TYPE bapisrmdoc-guid,
documentclass TYPE bapisrmdoc-docclass,
wa_file TYPE bapidocfiles,
lt_file TYPE TABLE OF bapidocfiles.
wa_comp TYPE bapidoccomp,
lt_comp TYPE TABLE of lt_comp.
...
wa_file-comp_id = 'my.txt'.
wa_file-directory = 'c:\temp\'.
wa_file-filename = 'my.txt'.
append wa_file to lt_file.
**********************************************************************
* if document has more than one file
CALL FUNCTION 'SRM_DOCUMENT_GET_COMP_INFO'
EXPORTING
objectid = objectid
documentclass = documentclass
TABLES
component_info = lt_comp
.
LOOP AT lt_comp INTO wa_comp.
,,wa_file-comp_id = wa_comp-comp_id.
wa_file-directory = 'c:\temp'.
wa_file-filename = wa_comp-comp_id.
APPEND wa_file to lt_file.
ENDLOOP.
**********************************************************
CALL FUNCTION 'SRM_DOCUMENT_CHECKOUT_VIA_FILE'
EXPORTING
objectid = objectid
documentclass = documentclass
* IMPORTING
* return = return
TABLES
file_tab = lt_file
.
*
Notes
Further information
Parameters
DOCUMENTCLASSDOC_CONTEXT
FILE_TAB
OBJECTID
RETURN
VARIANT
VERSION
X_SET_CHECKED_OUT
Exceptions
DOC_NOT_FOUNDINTERNAL_ERROR
NOT_AUTHORIZED
PARAMETER_ERROR
Function Group
SRM_BAPI_DOCUMENTGeneral Data in Customer Master RFUMSV00 - Advance Return for Tax on Sales/Purchases
This documentation is copyright by SAP AG.
Length: 2356 Date: 20240523 Time: 104023 sap01-206 ( 22 ms )