SAP C14SX_DOCUMENT_STATUS_CHANGE Function Module for NOTRANSL: EHS: Änderung des Dokumentstatus eines DVS-Dokuments









C14SX_DOCUMENT_STATUS_CHANGE is a standard c14sx document status change SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for NOTRANSL: EHS: Änderung des Dokumentstatus eines DVS-Dokuments 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 c14sx document status change FM, simply by entering the name C14SX_DOCUMENT_STATUS_CHANGE into the relevant SAP transaction such as SE37 or SE38.

Function Group: C14SX
Program Name: SAPLC14SX
Main Program: SAPLC14SX
Appliation area:
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:



Function C14SX_DOCUMENT_STATUS_CHANGE 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 'C14SX_DOCUMENT_STATUS_CHANGE'"NOTRANSL: EHS: Änderung des Dokumentstatus eines DVS-Dokuments
EXPORTING
I_DOCKEY = "
I_STATUS = "
I_PROTF = "
* I_DO_CHANGES = ESP1_TRUE "
* I_DO_SUCC_CHECKS = ESP1_TRUE "

TABLES
* E_EXTERROR_TAB = "Error Message Table

EXCEPTIONS
DOC_NOT_FOUND = 1 ILLEGAL_STATUS = 2 GENERAL_FAILURE = 3 STATUS_UNDEFINED = 4 LOCK_FAILED = 5 UPDATE_STATUS_FAILED = 6 UPDATE_PROTOCOL_FAILED = 7
.



IMPORTING Parameters details for C14SX_DOCUMENT_STATUS_CHANGE

I_DOCKEY -

Data type: CVDDOCKEY
Optional: No
Call by Reference: No ( called with pass by value option)

I_STATUS -

Data type: TDWST-DOKST
Optional: No
Call by Reference: No ( called with pass by value option)

I_PROTF -

Data type: DRAP-PROTF
Optional: No
Call by Reference: No ( called with pass by value option)

I_DO_CHANGES -

Data type: ESP1_BOOLEAN
Default: ESP1_TRUE
Optional: Yes
Call by Reference: No ( called with pass by value option)

I_DO_SUCC_CHECKS -

Data type: ESP1_BOOLEAN
Default: ESP1_TRUE
Optional: Yes
Call by Reference: No ( called with pass by value option)

TABLES Parameters details for C14SX_DOCUMENT_STATUS_CHANGE

E_EXTERROR_TAB - Error Message Table

Data type: ESPAP_EXTERROR_TAB_TYPE
Optional: Yes
Call by Reference: Yes

EXCEPTIONS details

DOC_NOT_FOUND -

Data type:
Optional: No
Call by Reference: No ( called with pass by value option)

ILLEGAL_STATUS -

Data type:
Optional: No
Call by Reference: No ( called with pass by value option)

GENERAL_FAILURE -

Data type:
Optional: No
Call by Reference: No ( called with pass by value option)

STATUS_UNDEFINED -

Data type:
Optional: No
Call by Reference: No ( called with pass by value option)

LOCK_FAILED -

Data type:
Optional: No
Call by Reference: No ( called with pass by value option)

UPDATE_STATUS_FAILED -

Data type:
Optional: No
Call by Reference: No ( called with pass by value option)

UPDATE_PROTOCOL_FAILED -

Data type:
Optional: No
Call by Reference: No ( called with pass by value option)

Copy and paste ABAP code example for C14SX_DOCUMENT_STATUS_CHANGE 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_i_dockey  TYPE CVDDOCKEY, "   
lv_doc_not_found  TYPE CVDDOCKEY, "   
lt_e_exterror_tab  TYPE STANDARD TABLE OF ESPAP_EXTERROR_TAB_TYPE, "   
lv_i_status  TYPE TDWST-DOKST, "   
lv_illegal_status  TYPE TDWST, "   
lv_i_protf  TYPE DRAP-PROTF, "   
lv_general_failure  TYPE DRAP, "   
lv_i_do_changes  TYPE ESP1_BOOLEAN, "   ESP1_TRUE
lv_status_undefined  TYPE ESP1_BOOLEAN, "   
lv_lock_failed  TYPE ESP1_BOOLEAN, "   
lv_i_do_succ_checks  TYPE ESP1_BOOLEAN, "   ESP1_TRUE
lv_update_status_failed  TYPE ESP1_BOOLEAN, "   
lv_update_protocol_failed  TYPE ESP1_BOOLEAN. "   

  CALL FUNCTION 'C14SX_DOCUMENT_STATUS_CHANGE'  "NOTRANSL: EHS: Änderung des Dokumentstatus eines DVS-Dokuments
    EXPORTING
         I_DOCKEY = lv_i_dockey
         I_STATUS = lv_i_status
         I_PROTF = lv_i_protf
         I_DO_CHANGES = lv_i_do_changes
         I_DO_SUCC_CHECKS = lv_i_do_succ_checks
    TABLES
         E_EXTERROR_TAB = lt_e_exterror_tab
    EXCEPTIONS
        DOC_NOT_FOUND = 1
        ILLEGAL_STATUS = 2
        GENERAL_FAILURE = 3
        STATUS_UNDEFINED = 4
        LOCK_FAILED = 5
        UPDATE_STATUS_FAILED = 6
        UPDATE_PROTOCOL_FAILED = 7
. " C14SX_DOCUMENT_STATUS_CHANGE




ABAP code using 7.40 inline data declarations to call FM C14SX_DOCUMENT_STATUS_CHANGE

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.

 
 
 
"SELECT single DOKST FROM TDWST INTO @DATA(ld_i_status).
 
 
"SELECT single PROTF FROM DRAP INTO @DATA(ld_i_protf).
 
 
DATA(ld_i_do_changes) = ESP1_TRUE.
 
 
 
DATA(ld_i_do_succ_checks) = ESP1_TRUE.
 
 
 


Search for further information about these or an SAP related objects



Comments on this SAP object

What made you want to lookup this SAP object? Please tell us what you were looking for and anything you would like to be included on this page!