Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

ABAP Program to upload accrual object using ACAC_OBJECT_MODIFY_EXT

Former Member
0 Kudos

I have a requirement to develop an RFC to call the ACAC_OBJECT_MODIFY_EXT function module for accrual upload. I have created the BAPI / ALE interface for it to be used in LSMW. However the program returns a DUMP when calling the function module because of the parameter passed. I need help with this. A program using this function module would do it for me.

Here is the interface for the  FM


CALL FUNCTION 'ACAC_OBJECT_MODIFY_EXT' "

* EXPORTING

* is_assignments = " ace_assignments

* it_accounts = " aceds_accounts_t

* it_params = " aceds_param_t

* id_effdate = " ace_effdate

* is_post_params = " aceps_manual_posting_params

* id_testrun = 'X' " ace_testrun

  IMPORTING

  ed_data_created = " flag

  ed_data_changed = " flag

  et_docitems = " aceps_ace_doc_extended_t

  et_return = " bapiret2_t

  et_accdoc_return = " ace_accdoc_return_t

  CHANGING

  cs_object = " acac_object_header_ext

  ct_object_items = " aceds_items_t

  .

Typical error:

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 "ZBAPIACCRUALUPLOAD" "(FUNCTION)", nor was it propagated by a RAISING

  clause.

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:

The call to the function module "ACAC_OBJECT_MODIFY_EXT" is incorrect:

The function module interface allows you to specify only

fields of a particular type under "IT_ACCOUNTS".

The field "ACCOUNTS" specified here is a different

field type

.

Attached to the file is the source code of the rfc i am trying to create( ZBAPIACCRUALUPLOAD)

Regards,

2 REPLIES 2

former_member198275
Active Contributor
0 Kudos

Hi,

Can you declare like below , hopefully with header line is not required.

DATA : ACCOUNTS TYPE ACEDS_ACCOUNTS_T,

refer this include ACAC_GENERIC_DATA_TRANSF_F10

0 Kudos

Hi,

Thanks for your suggestion, but when I remove the with header line, it also shows that table does not have header line. P|ease I would like a simple program that uses this FM passing all its parameters.