Application Development and Automation 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: 
Read only

BAPI_ACC_DOCUMENT_POST Error Cmmt item

Former Member
0 Likes
1,245

Hi guys,

I am using the BAPI "BAPI_ACC_DOCUMENT_POST". It was working fine until the field "Commitment Item" was changed to OBLIGATORY. I tried so many times to add it to the bapi, but it doesnt work, it gives me an error F5 808, Field Cmmt Item is a required field for G/L account 1000 22200406.

this is the estructure that i am using with this BAPI.

CALL FUNCTION 'BAPI_ACC_DOCUMENT_POST'

EXPORTING

documentheader = ti_header

customercpd = ti_cus_ven2

  • CONTRACTHEADER =

IMPORTING

obj_type = obj_type2

obj_key = obj_key2

obj_sys = obj_sys2

TABLES

accountgl = ti_mayor

accountreceivable = ti_deudor

accountpayable = ti_acreedor

accounttax = ti_impto

currencyamount = ti_monto

criteria = ti_criterio

  • VALUEFIELD =

  • EXTENSION1 =

return = ti_mensaje

  • PAYMENTCARD =

  • CONTRACTITEM =

extension2 = ti_exten

  • REALESTATE =

accountwt = ti_imptowt.

i was able to add it in :

ti_mayor-cmmt_item = ti_datofi-fipos.

ti_mayor-CMMT_ITEM_LONG = ti_datofi-fipos.

but i couldnt find the way to add it at it_acreedor. So, probably that's why it doesnt work.

Please, give me some advice.

Where can i add that field to the bapi?? thanks

Regards

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
988

Are you using Funds Management?

Rob

4 REPLIES 4
Read only

Former Member
0 Likes
988

I don't think you need to add it to the vendor - just the GL items.

Rob

Read only

0 Likes
988

Hi Rob,

I added to the accountgl item, but it doesnt work.

Do u have any idea why? if i post a document by f-02 it askes me for the cmmt item twice, for example i do a mov. 40 and askes it and then the second mov. 31 and it askes me again, because it is an obligatory field. but in the bapi i added to the accountgl where just one mov is on it, so i thought that i must add it in another table.

is it correct?

Thanks in advice.

PD: Before, i didnt use the commy field and the bapi worked fine.

Read only

Former Member
0 Likes
989

Are you using Funds Management?

Rob

Read only

0 Likes
988

Hi Rob,

thanks for ur replies, but the problem was sth in customizing, so now it is working fine.

thanks, bye bye