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

CALCULATE_TAX_DOCUMENT + without error by default ?

former_member202771
Contributor
0 Likes
4,023

Hi Experts,

I am working on a custom idoc interface for invoice posting. I am using bapi_acc_invoice_receipt_post.

Issue:

I need to show the vertex error with taxes as bapi return message, as it shows while posting in FB60 - Tax entered incorrect (code I1, amount 10.00), correct 14.00 USD

But when using BAPI, I see that this error message is by-passed for reason I am unknown of.

Can you please help me with your expertise for understanding why this was bypassed and what are the implications of clearing the above mentioned flag using any exit/enho.

And firstly I also wanted to ask, if anyone was able to show this tax error message in BAPI return > - Tax entered incorrect (code I1, amount 10.00), correct 14.00 USD.

Thanks and Regards,

Anil Supraj

1 ACCEPTED SOLUTION
8 REPLIES 8
Read only

0 Likes
2,825

Hi Pablo,

2274792 - Accounting Interface: messages FF707 / FF724 do not appear

This seems to be an apt note. Hopefully this will solve my issue . I have asked my concerned team to implement it. I am keeping the thread open till tomorrow, just in case it doesn't work.

Will close the thread tomorrow as soon as my note is implemented and working as expected.

Many thanks for the help.

Regards,

Anil

Read only

0 Likes
2,825

Hi Pablo,

I have implemented 2274792 - Accounting Interface: messages FF707 / FF724 do not appear

However, BAPI error is populated wrongly. In my case tax rate is 14%.

I have sent 2 gl line items one with 100 and other with 200 as item amount and corresponding tax amounts as 14 and 28.

The document should have been posted. But I get below error.


It adds both line tax amount and compares with tax rate and throws error. Any thoughts, why tax is getting added?

Is it something related to tax procedure, to calculate tax line by line?

For tax line-by-line if have done below code at include ZXACCU15:

READ TABLE extension WITH KEY field1 = 'TAXPS'.

  IF sy-subrc EQ 0.  "Fill the tax line item number for DS and BO2 scenarios

    LOOP AT t_accit ASSIGNING <fs_accit>.

      <fs_accit>-taxps = 000001.

    ENDLOOP.

    LOOP AT t_acctx ASSIGNING <fs_acctx>.

      <fs_acctx>-taxps = 000001.

    ENDLOOP.

  ENDIF.

UNASSIGN: <fs_accit>, <fs_acctx>.


Thanks,

Anil

Read only

0 Likes
2,825

Hi,

regarding message RW 609:

have you identified why is it being raised?

put some break-points here

and check what is going on.

Best regards,

Pablo

Read only

0 Likes
2,825

The issue was due to below:

    LOOP AT t_accit ASSIGNING <fs_accit>.

      <fs_accit>-taxps = 000001.

    ENDLOOP.

    LOOP AT t_acctx ASSIGNING <fs_acctx>.

      <fs_acctx>-taxps = 000001.

    ENDLOOP.

All tax lined has same TAXPS value. So tax was getting summed up. incremented via counter to solve the error.

Thanks,

Anil

Read only

0 Likes
2,825

Hi,

something like this?:

Best regards,

Pablo

Read only

0 Likes
2,825

yes Pablo. That doc written by me

Read only

0 Likes
2,825

Good one!

congrats!