SAP COPCA_ACTIVE_ACT Function Module for









COPCA_ACTIVE_ACT is a standard copca active act SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used to perform a specific ABAP function and below is the pattern details, 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 copca active act FM, simply by entering the name COPCA_ACTIVE_ACT into the relevant SAP transaction such as SE37 or SE38.

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



Function COPCA_ACTIVE_ACT 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 'COPCA_ACTIVE_ACT'"
EXPORTING
GJAHR = "
KOKRS = "
PCRCH = "

IMPORTING
EPSKZ = "
PCA_VALU = "
LMONA = "
ONLKZ = "
PCACUR = "
PCACURTP = "
PCATRCUR = "
VSPKZ = "
PCBEL = "
DPRCT = "

EXCEPTIONS
COPCA_NOT_ACTIVE = 1 KOKRS_NOT_FOUND = 2 WRONG_PARAMETER_PCRCH = 3 NO_CURRENCY_FOUND = 4
.



IMPORTING Parameters details for COPCA_ACTIVE_ACT

GJAHR -

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

KOKRS -

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

PCRCH -

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

EXPORTING Parameters details for COPCA_ACTIVE_ACT

EPSKZ -

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

PCA_VALU -

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

LMONA -

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

ONLKZ -

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

PCACUR -

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

PCACURTP -

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

PCATRCUR -

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

VSPKZ -

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

PCBEL -

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

DPRCT -

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

EXCEPTIONS details

COPCA_NOT_ACTIVE -

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

KOKRS_NOT_FOUND -

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

WRONG_PARAMETER_PCRCH -

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

NO_CURRENCY_FOUND -

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

Copy and paste ABAP code example for COPCA_ACTIVE_ACT 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_epskz  TYPE TKA00PCA-EPSKZ, "   
lv_gjahr  TYPE TKA00-GJAHR, "   
lv_copca_not_active  TYPE TKA00, "   
lv_pca_valu  TYPE TKA01-PCA_VALU, "   
lv_kokrs  TYPE TKA00-KOKRS, "   
lv_lmona  TYPE TKA01-LMONA, "   
lv_kokrs_not_found  TYPE TKA01, "   
lv_onlkz  TYPE TKA00PCA-ONLKZ, "   
lv_pcrch  TYPE TKA00-PCRCH, "   
lv_wrong_parameter_pcrch  TYPE TKA00, "   
lv_pcacur  TYPE TKA01-PCACUR, "   
lv_no_currency_found  TYPE TKA01, "   
lv_pcacurtp  TYPE TKA01-PCACURTP, "   
lv_pcatrcur  TYPE TKA01-PCATRCUR, "   
lv_vspkz  TYPE TKA00PCA-VSPKZ, "   
lv_pcbel  TYPE TKA01-PCBEL, "   
lv_dprct  TYPE TKA01-DPRCT. "   

  CALL FUNCTION 'COPCA_ACTIVE_ACT'  "
    EXPORTING
         GJAHR = lv_gjahr
         KOKRS = lv_kokrs
         PCRCH = lv_pcrch
    IMPORTING
         EPSKZ = lv_epskz
         PCA_VALU = lv_pca_valu
         LMONA = lv_lmona
         ONLKZ = lv_onlkz
         PCACUR = lv_pcacur
         PCACURTP = lv_pcacurtp
         PCATRCUR = lv_pcatrcur
         VSPKZ = lv_vspkz
         PCBEL = lv_pcbel
         DPRCT = lv_dprct
    EXCEPTIONS
        COPCA_NOT_ACTIVE = 1
        KOKRS_NOT_FOUND = 2
        WRONG_PARAMETER_PCRCH = 3
        NO_CURRENCY_FOUND = 4
. " COPCA_ACTIVE_ACT




ABAP code using 7.40 inline data declarations to call FM COPCA_ACTIVE_ACT

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 EPSKZ FROM TKA00PCA INTO @DATA(ld_epskz).
 
"SELECT single GJAHR FROM TKA00 INTO @DATA(ld_gjahr).
 
 
"SELECT single PCA_VALU FROM TKA01 INTO @DATA(ld_pca_valu).
 
"SELECT single KOKRS FROM TKA00 INTO @DATA(ld_kokrs).
 
"SELECT single LMONA FROM TKA01 INTO @DATA(ld_lmona).
 
 
"SELECT single ONLKZ FROM TKA00PCA INTO @DATA(ld_onlkz).
 
"SELECT single PCRCH FROM TKA00 INTO @DATA(ld_pcrch).
 
 
"SELECT single PCACUR FROM TKA01 INTO @DATA(ld_pcacur).
 
 
"SELECT single PCACURTP FROM TKA01 INTO @DATA(ld_pcacurtp).
 
"SELECT single PCATRCUR FROM TKA01 INTO @DATA(ld_pcatrcur).
 
"SELECT single VSPKZ FROM TKA00PCA INTO @DATA(ld_vspkz).
 
"SELECT single PCBEL FROM TKA01 INTO @DATA(ld_pcbel).
 
"SELECT single DPRCT FROM TKA01 INTO @DATA(ld_dprct).
 


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!