I am trying to re-post for a given set of GL Accounts using this BAPI.
I am passing the header data for the BAPI Call from "BKPF" Table.
On BAPI Call, my return table gets filled with 3 lines of errors.
1. Error in document
2. Object Type "BKPF" not expected. wrong object type passed to the Parameter OBJ_TYPE of Header (something like this...)
3. Parameter OBJ_SYS not filled in the structure passed to the Header during BAPI Call.
I am filling the OBJ_TYPE and OBJ_SYS Parameters from BKPF-AWTYP and BKPF-AWSYS.
They are values taken from the Table records only.
Any ideas on what the problem could be? Any help in this direction is appreciated.
Thanks in advance.