Bapi_acc_document_post Import Foreign Currency Amount __ABAP Technology

Source: Internet
Author: User
When you use Bapi_acc_document_post to do a voucher period import, you import foreign currencies, there are two ways to do this.


1, directly specify the exchange rate (there will be the tail difference).


2, enter local and foreign currency amount directly (no trailing difference)


IF wa_post-waers <> ' CNY '.


L_currencyamount-amt_doccur = l_dmbtr. "Amount


L_currencyamount-curr_type = ' 10 '.


l_currencyamount-currency = ' CNY '.


APPEND L_currencyamount to Li_currencyamount.


L_currencyamount-amt_doccur = l_wrbtr. "Amount


L_currencyamount-curr_type = ' 00 '.


L_currencyamount-currency = Wa_post-waers.


APPEND L_currencyamount to Li_currencyamount.


ELSE.


L_currencyamount-amt_doccur = l_wrbtr. "Amount


L_currencyamount-currency = Wa_post-waers.


APPEND L_currencyamount to Li_currencyamount.


* L_currencyamount-exch_rate = (WA_POST-DMBTR)/WA_POST-WRBTR. "Exchange rate


ENDIF.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.