Skip to Content
Former Member
Apr 11, 2009 at 11:19 PM

Issue with a "perform in program" call.


I am trying to do a call to a form in a zprogram. This call is being done inside an enhancement. The reason for this is because I can't delcare forms in the enhancement. Below is the issue:

The parameters I am trying to pass are typed as follows (in the SAP enhancement - SAP code):

types: begin of mrm_rbkpv.
        include structure rbkp_v.
types: begin of mmcr_drseg.
        include structure drseg.
types: mmcr_tdrseg type mmcr_drseg occurs 0.

I have the following as the call to the form and the form declaration:

PERFORM cancel_ret IN PROGRAM zcancel_retention USING e_trbkpv e_tdrseg[].

FORM cancel_ret  USING p_tdrseg TYPE rbkp_v
                      it_tdrseG TYPE J_1IDRSEG.

I am getting a run-time error saying:

An exception occurred that is explained in detail below.

The exception, which is assigned to class 'CX_SY_DYN_CALL_ILLEGAL_TYPE', was

not caught in

procedure "EXIT_SAPLMRMP_010" "(FUNCTION)", nor was it propagated by a RAISING


Since the caller of the procedure could not have anticipated that the

exception would occur, the current program is terminated.

The reason for the exception is:

Call to FORM "CANCEL_RET" is incorrect:

The actual parameter no. 1 has a different data type in the

PERFORM than requested for the FORM "CANCEL_RET" in program


This is telling me that the system doesn't see e_trbkpv being the same type as p_tdrseg. However, I can't see why they aren't the same time. I also assume I will have the issue with the second parameter. The table type (in my opinion) J_1IDRSEG should be the same type as mmcr_drseg.

Any ideas? The enhancement I am using is EXIT_SAPLMRMP_010 (LMR1M001).



Edited by: Aaron Shover on Apr 11, 2009 7:21 PM