IF gs_disave-waers <> 'CNY'. CALL FUNCTION 'CONVERT_TO_LOCAL_CURRENCY' EXPORTING * CLIENT = SY-MANDT date = l_date "当前日期 foreign_amount = gs_disave-netpr “外币金额 foreign_currency = gs_disave-waers ”外币如:USD local_currency = 'CNY' “本币:人民币 * RATE = 0 type_of_rate = 'M' ”平均 * READ_TCURR = 'X' IMPORTING * EXCHANGE_RATE = * FOREIGN_FACTOR = local_amount = l_netpr “转化后得到的本币金额:人民币金额 * LOCAL_FACTOR = * EXCHANGE_RATEX = * FIXED_RATE = * DERIVED_RATE_TYPE = EXCEPTIONS no_rate_found = 1 overflow = 2 no_factors_found = 3 no_spread_found = 4 derived_2_times = 5 OTHERS = 6 . IF sy-subrc <> 0. MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4. ENDIF.