10-03-2017 7:26 AM
Hello all,
I want to update Tax Code field (in me31k and me32k) while saving ,
for this i have used exit EXIT_SAPMM06E_012 ,
but its not updating the Tax code,
below is my code,
if sy-tcode eq 'ME32K' or sy-tcode eq 'ME31K'.
if i_ekko-bsart is NOT INITIAL.
select SINGLE * FROM ZMM_AGMT_TAX INTO wa_agmt_tax WHERE zbsart eq i_ekko-bsart.
if sy-subrc = 0.
lv_agmt_tax = wa_agmt_tax-zmwskz.
endif.
if tekpo[] is NOT INITIAL.
loop at tekpo into wa_tekpo.
wa_tekpo-mwskz = lv_agmt_tax.
MODIFY tekpo FROM wa_tekpo TRANSPORTING mwskz.
endloop.
endif.
endif.
endif.
where in ZMM_AGMT_TAX we are maintaing some tax codes based om agmt type BSART.
thanks in advance..
10-03-2017 10:27 AM
This Exit FM is only provided for check, with a simple 'where-used' search you will note that it works with a local copy of data, so don't expect that changing those data will be copied back to main program, only the header customer fields can be changed (changing parameter c_ci_ekko)
Alas, no BAdI seem available (read 2300802 - ME_PROCESS_OUT_CUST is not called in ME31L/ME32L/ME31K/ME32K.) only the exit you found and it's only purpose is check, so you should look for some implicit enhancement for example.