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: 

Withholding Data With GL Posting BAPI

Former Member
0 Kudos

Greetings,

I am trying to use BAPI_ACC_GL_POSTING_POST to post line items (two of which are for state and federal withholding). I am using an extension to send exit EXIT_SAPLACC4_001 some custom fields data and withholding data (through structure ACCIT_WT). When I run the program that calls the bapi, I get desired reults for the line items I expect to see in the posted document. However, when I double-click on the line item for which I expect to see withholding tax data there are problems. Withholding tax code does not exist and none of the amounts that I am sending show up. The Withholding tax types and names of the withholding tax types are the only fields that show up in the subscreen "Display Withholding Tax Info" of transaction F-43. Can someone please give me some insight into what I am doing wrong. I am sending the following fields for structure ACCIT_WT:

WITHT

WT_WITHCD

WT_QSSHH

WT_QSSHB

WT_BASMAN

and I have tried sending values for the other fields.

Does the grouping key WT_KEY have anything to do with my problem?

Your assistance is greatly anticipated. Thanks in advance.

Kind Regards,

Jason

5 REPLIES 5

former_member185932
Participant
0 Kudos

Hi Jason,

Sorry to resurrect an old topic.

I assume you managed to fix this problem? I found that I was able to get the system to automatically calculate the Extended Withholding Tax when using BAPI_ACC_DOCUMENT_POST by populating the following fields:

IT_ACCIT-WT_KEY - link from the line item to the Withholding Tax data.

IT_ACCWT-WT_KEY - same value as above.

IT_ACCWT-WITHT - Withholding Tax type.

IT_ACCWT-WT_WITHCD - Withholding Tax code.

IT_ACCWT-WT_QSSHB - Withholding Tax Base amount in doc curr.

I left the WT_BASMAN field empty.

Hope this helps someone out there.

Cheers,

JB

0 Kudos

Hi!

I'm using BAPI_ACC_DOCUMENT_POST and the Table ACCOUNTWT to pass Withholding Tax information but it doesn't work. Where do I fill the internal table IT_ACCIT?

Regards,

Mário Espinheira

0 Kudos

Hi resurrecting this topic again.

I am facing the same problem. Could anyone post some tips?

0 Kudos

I am facing the same problem too.

I can't add withholding tax items to my Acc. Document

Any suggests?

ravi_rajput
Participant
0 Kudos

It_accit -wt_key should be synonymous with the it_accwt-wt_key.
For example if you have got a one line item with vendor. Pass the amount and witholding tax code from internal table and table lfbw.
In the user/customer exit.

Just make sure that the it_accit-wt_key is equal to it_accwt-wt_key. You could use modify statement with a particular vendor key per se '31'. if It_accit-wt_key is equal to it_accit-wt_key, then tax will get calculated for sure for that particular line item. Good luck.