Skip to Content
0
Former Member
Nov 28, 2011 at 05:29 PM

CU65 Variant Function cannot be released - check function module interface

162 Views

Hi ,

Getting this error while Releasing the variant Function in CU66. Function Module trigerred by this function is of the same name as well as correctly acitvated and released , but while releasing the Function I get this error : 'Function cannot be released - check function module interface' . Following are two characeteristics that are maintained in the variant function :

1. Customer_Type

2. Maintenance_Contract

While executing the Function Module alone I get Raise Inernal Exception i.e it is not identifying the argument name 'Maintenance_Contract' in the FM 'CUOV_GET_FUNCTION_ARGUMENT' exception

Below is the code for reference . Pls point out if any mistakes :

*"----


""Local Interface:

*" IMPORTING

*" REFERENCE(GLOBALS) TYPE CUOV_00

*" CHANGING

*" REFERENCE(ZQUERY) TYPE ZQUERY

*" REFERENCE(ZMATCH) TYPE ZMATCH

*" EXCEPTIONS

*" FAIL

*" INTERNAL_ERROR

*"----


" Data Declaration

DATA : l_main LIKE CUOV_01-atwrt,

l_cust LIKE CUOV_01-atwrt.

" Get value of Input Characteristic Maintenance Contract

call function 'CUOV_GET_FUNCTION_ARGUMENT'

exporting

argument = 'MAINTENANCE_CONTRACT'

IMPORTING

SYM_VAL = l_main

tables

query = ZQUERY

EXCEPTIONS

ARG_NOT_FOUND = 1

.

if sy-subrc <> 0.

RAISE INTERNAL_ERROR.

endif.

" Get value of Input Characteristic Customer Type

call function 'CUOV_GET_FUNCTION_ARGUMENT'

exporting

argument = 'CUSTOMER_TYPE'

IMPORTING

SYM_VAL = l_cust

tables

query = ZQUERY

EXCEPTIONS

ARG_NOT_FOUND = 1

.

if sy-subrc <> 0.

RAISE INTERNAL_ERROR.

endif.

IF l_main EQ 'NO'.

IF l_cust EQ 'CURRENT'.

l_cust = 'NEW'.

ELSEIF l_cust EQ 'VAR CURRENT'.

l_cust = 'VAR NEW'.

ENDIF.

ENDIF.

" Set value for the output characteristic

call function 'CUOV_SET_FUNCTION_ARGUMENT'

exporting

argument = 'CUSTOMER_TYPE'

vtype = 'CHAR'

SYM_VAL = l_cust

  • NUM_VAL =

tables

match = ZMATCH

EXCEPTIONS

EXISTING_VALUE_REPLACED = 1