Posted: Thu Sep 20, 2007 11:11 am Post subject: SD_PRINT_TERMS_OF_PAYMENT
SD_PRINT_TERMS_OF_PAYMENT - Format Terms of Payment According to Table 052
Code:
form move_tvzbt_to_vbdkr.
move tvzbt-vtext to vbdkr-zterm_bez.
xfkdat = vbrk-fkdat + vbrk-valtg.
if vbrk-valdt ne 0.
xfkdat = vbrk-valdt.
endif.
call function 'SD_PRINT_TERMS_OF_PAYMENT'
exporting
terms_of_payment = vbdkr-zterm
bldat = xfkdat
budat = xfkdat
cpudt = xfkdat
language = vbco3-spras
country = vbdkr-land1
importing
payment_split = vbdkr-p_split
zfbdt = vbdkr-zfbdt
tables
top_text = zterm
exceptions
terms_of_payment_not_in_t052 = 1.
if not sy-subrc is initial.
message id sy-msgid type sy-msgty number sy-msgno
with sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4
raising terms_of_payment_not_in_t052.
endif.
* CHECK SY-SUBRC = 0.
loop at zterm.
case sy-tabix.
when 1.
move zterm-line to vbdkr-zterm_tx1.
when 2.
move zterm-line to vbdkr-zterm_tx2.
when 3.
move zterm-line to vbdkr-zterm_tx3.
endcase.
endloop.
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You cannot attach files in this forum You cannot download files in this forum
All product names are trademarks of their respective companies. SAPNET.RU websites are in no way affiliated with SAP AG. SAP, SAP R/3, R/3 software, mySAP, ABAP, BAPI, xApps, SAP NetWeaver and any other are registered trademarks of SAP AG. Every effort is made to ensure content integrity. Use information on this site at your own risk.