<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: currency conversion in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/currency-conversion/m-p/2019762#M413245</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Check this example&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: v_amount TYPE p DECIMALS 2.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'CONVERT_TO_FOREIGN_CURRENCY'&lt;/P&gt;&lt;P&gt;EXPORTING&lt;/P&gt;&lt;P&gt;date = sy-datum&lt;/P&gt;&lt;P&gt;foreign_currency = 'INR'&lt;/P&gt;&lt;P&gt;local_amount = '1.00'&lt;/P&gt;&lt;P&gt;local_currency = 'USD'&lt;/P&gt;&lt;P&gt;IMPORTING&lt;/P&gt;&lt;P&gt;foreign_amount = v_amount&lt;/P&gt;&lt;P&gt;EXCEPTIONS&lt;/P&gt;&lt;P&gt;no_rate_found = 1&lt;/P&gt;&lt;P&gt;overflow = 2&lt;/P&gt;&lt;P&gt;no_factors_found = 3&lt;/P&gt;&lt;P&gt;no_spread_found = 4&lt;/P&gt;&lt;P&gt;derived_2_times = 5&lt;/P&gt;&lt;P&gt;OTHERS = 6.&lt;/P&gt;&lt;P&gt;IF sy-subrc = 0.&lt;/P&gt;&lt;P&gt;WRITE: / 'US dollar to Indian rupees - ', v_amount.&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Kishore.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 16 Mar 2007 09:30:45 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-03-16T09:30:45Z</dc:date>
    <item>
      <title>currency conversion</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/currency-conversion/m-p/2019761#M413244</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Could u pls help me to convert US dollar to EURO?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 16 Mar 2007 09:26:33 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/currency-conversion/m-p/2019761#M413244</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-03-16T09:26:33Z</dc:date>
    </item>
    <item>
      <title>Re: currency conversion</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/currency-conversion/m-p/2019762#M413245</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Check this example&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: v_amount TYPE p DECIMALS 2.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'CONVERT_TO_FOREIGN_CURRENCY'&lt;/P&gt;&lt;P&gt;EXPORTING&lt;/P&gt;&lt;P&gt;date = sy-datum&lt;/P&gt;&lt;P&gt;foreign_currency = 'INR'&lt;/P&gt;&lt;P&gt;local_amount = '1.00'&lt;/P&gt;&lt;P&gt;local_currency = 'USD'&lt;/P&gt;&lt;P&gt;IMPORTING&lt;/P&gt;&lt;P&gt;foreign_amount = v_amount&lt;/P&gt;&lt;P&gt;EXCEPTIONS&lt;/P&gt;&lt;P&gt;no_rate_found = 1&lt;/P&gt;&lt;P&gt;overflow = 2&lt;/P&gt;&lt;P&gt;no_factors_found = 3&lt;/P&gt;&lt;P&gt;no_spread_found = 4&lt;/P&gt;&lt;P&gt;derived_2_times = 5&lt;/P&gt;&lt;P&gt;OTHERS = 6.&lt;/P&gt;&lt;P&gt;IF sy-subrc = 0.&lt;/P&gt;&lt;P&gt;WRITE: / 'US dollar to Indian rupees - ', v_amount.&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Kishore.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 16 Mar 2007 09:30:45 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/currency-conversion/m-p/2019762#M413245</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-03-16T09:30:45Z</dc:date>
    </item>
    <item>
      <title>Re: currency conversion</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/currency-conversion/m-p/2019763#M413246</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Use FM &lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;CONVERT_TO_FOREIGN_CURRENCY
CONVERT_TO_LOCAL_CURRENCY
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Santosh&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 16 Mar 2007 09:32:36 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/currency-conversion/m-p/2019763#M413246</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-03-16T09:32:36Z</dc:date>
    </item>
    <item>
      <title>Re: currency conversion</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/currency-conversion/m-p/2019764#M413247</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;PRE&gt;&lt;CODE&gt;      CALL FUNCTION 'CONVERT_TO_FOREIGN_CURRENCY'     " Convert to Manuf
           EXPORTING                                  " currency
                DATE             = ZVBRP-PRSDT
*               date             = sy-datum
                FOREIGN_CURRENCY = T001-WAERS
                LOCAL_AMOUNT     = Z1KOMV-KWERT
                LOCAL_CURRENCY   = Z1KOMV-WAERS
*               RATE             = 0
                TYPE_OF_RATE     = 'M'
           IMPORTING
                FOREIGN_AMOUNT   = Z1KOMV-KWERT
           EXCEPTIONS
                NO_RATE_FOUND    = 1
                OVERFLOW         = 2
                NO_FACTORS_FOUND = 3
                NO_SPREAD_FOUND  = 4
                OTHERS           = 5.
      IF SY-SUBRC IS INITIAL.
        IRPT-CINVAMT = IRPT-CINVAMT + Z1KOMV-KWERT.
      ENDIF.

&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can even use &amp;lt;b&amp;gt;MS_CONVERT_TO_OTHER_CURRENCY&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 16 Mar 2007 09:34:54 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/currency-conversion/m-p/2019764#M413247</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-03-16T09:34:54Z</dc:date>
    </item>
    <item>
      <title>Re: currency conversion</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/currency-conversion/m-p/2019765#M413248</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Try this......&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SD_CONVERT_CURRENCY&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 16 Mar 2007 09:36:11 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/currency-conversion/m-p/2019765#M413248</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-03-16T09:36:11Z</dc:date>
    </item>
    <item>
      <title>Re: currency conversion</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/currency-conversion/m-p/2019766#M413249</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;check this it may help you......&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;CALL FUNCTION 'CONVERT_TO_LOCAL_CURRENCY'
       EXPORTING
*    CLIENT                  = 001
        DATE                    = sy-datum
         FOREIGN_CURRENCY        = wa1-WAERS " here you need to declare your foreign currency i.e EURO
         LOCAL_CURRENCY          = TCURR-FCURR "give USD
         FOREIGN_AMOUNT          = wa1-DMBTR " here you need to declare your amount field.
*    RATE                    = tcurr-ukurs
        TYPE_OF_RATE            = 'M'        " check this also the average rate
*    READ_TCURR              = 'X'
      IMPORTING
        EXCHANGE_RATE           = tcurr-UKURS
*    FOREIGN_FACTOR          =
        LOCAL_AMOUNT            = wa1-TOTAL  " this is the field where the converted amt has to be displayed.
*    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 &amp;lt;&amp;gt; 0.
** MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
**         WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Translate foreign currency amount to local currency&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;An amount in local currency is calculated from a specified foreign currency amount.&lt;/P&gt;&lt;P&gt; For this, you may either specify the translation rate manually (Parameter RATE) &lt;/P&gt;&lt;P&gt;or have the system determine it from table TCURR on the basis of the rate type, date and currency key.&lt;/P&gt;&lt;P&gt; Because the ratios for the units of the currencies involved in the translation are significant for this translation,&lt;/P&gt;&lt;P&gt; table TCURF is always read by the program, and there must be a valid entry there for the data specified. &lt;/P&gt;&lt;P&gt;IF exchange rate fixing is defined for the exchange rate type TYPE_OF_RATE or an alternative exchange rate is defined for the currency pair, this information is transferred to the calling program.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When table TCURR is read, the foreign currency key is always taken as the first part of the key and the local currency as the second part.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;hope this helps you.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards,&lt;/P&gt;&lt;P&gt;Anversha.S&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 16 Mar 2007 09:36:33 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/currency-conversion/m-p/2019766#M413249</guid>
      <dc:creator>anversha_s</dc:creator>
      <dc:date>2007-03-16T09:36:33Z</dc:date>
    </item>
    <item>
      <title>Re: currency conversion</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/currency-conversion/m-p/2019767#M413250</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;CALL FUNCTION 'SD_CONVERT_CURRENCY'&lt;/P&gt;&lt;P&gt;      EXPORTING&lt;/P&gt;&lt;P&gt;        i_date            = sy-datum&lt;/P&gt;&lt;P&gt;        i_source_amount   = vbap-zwert " Source Amt&lt;/P&gt;&lt;P&gt;        i_source_currency = vbak-waerk " Source Currency&lt;/P&gt;&lt;P&gt;        i_local_currency  = vbak-waers   " Local Currency&lt;/P&gt;&lt;P&gt;        i_target_currency = w_waers     " Target Currency&lt;/P&gt;&lt;P&gt;      IMPORTING&lt;/P&gt;&lt;P&gt;        e_target_amount   = lv_zwert      " Target Amount&lt;/P&gt;&lt;P&gt;      EXCEPTIONS&lt;/P&gt;&lt;P&gt;        no_rate_found     = 1.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 16 Mar 2007 09:41:24 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/currency-conversion/m-p/2019767#M413250</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-03-16T09:41:24Z</dc:date>
    </item>
  </channel>
</rss>

