<?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: CONVERT_TO_LOCAL_CURRENCY function in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/convert-to-local-currency-function/m-p/3206570#M764442</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks for all,&lt;/P&gt;&lt;P&gt;But when I execute function CONVERT_TO_FOREIGN_CURRENCY as:&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             = it_item-budat&lt;/P&gt;&lt;P&gt;              foreign_currency = it_item-waerk&lt;/P&gt;&lt;P&gt;              local_amount     = it_item-dmbtr&lt;/P&gt;&lt;P&gt;              local_currency   = it_item-waers&lt;/P&gt;&lt;P&gt;            IMPORTING&lt;/P&gt;&lt;P&gt;              exchange_rate    = it_item-kursf  "Exchange rate&lt;/P&gt;&lt;P&gt;              foreign_amount   = it_item-wrbtr. "Tax Amount(Document)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Don't have any error.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 17 Dec 2007 07:33:01 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-12-17T07:33:01Z</dc:date>
    <item>
      <title>CONVERT_TO_LOCAL_CURRENCY function</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/convert-to-local-currency-function/m-p/3206564#M764436</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi gurus,&lt;/P&gt;&lt;P&gt;I call this function, eg:&lt;/P&gt;&lt;P&gt;          CALL FUNCTION 'CONVERT_TO_LOCAL_CURRENCY'&lt;/P&gt;&lt;P&gt;            EXPORTING&lt;/P&gt;&lt;P&gt;              DATE                    = it_item-budat&lt;/P&gt;&lt;P&gt;              FOREIGN_AMOUNT          = it_item-dmbtr&lt;/P&gt;&lt;P&gt;              FOREIGN_CURRENCY        = it_item-waers&lt;/P&gt;&lt;P&gt;LOCAL_CURRENCY          = it_item-waerk&lt;/P&gt;&lt;P&gt;        IMPORTING&lt;/P&gt;&lt;P&gt;             EXCHANGE_RATE           = it_item-kursf&lt;/P&gt;&lt;P&gt;             LOCAL_AMOUNT            = it_item-wrbtr&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;U&gt;Get error:&lt;/U&gt;&lt;/P&gt;&lt;P&gt;Function parameter "EXCHANGE_RATE" is unknown.&lt;/P&gt;&lt;P&gt;Pls help me fix it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edited by: Bach Mieu Nguyen on Dec 17, 2007 8:00 AM&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 17 Dec 2007 06:58:58 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/convert-to-local-currency-function/m-p/3206564#M764436</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-12-17T06:58:58Z</dc:date>
    </item>
    <item>
      <title>Re: CONVERT_TO_LOCAL_CURRENCY function</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/convert-to-local-currency-function/m-p/3206565#M764437</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Check this thread below guess you will find a use full solution.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://www.sdn.sap.com/irj/sdn/forums" target="test_blank"&gt;https://www.sdn.sap.com/irj/sdn/forums&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Reward if found usefull.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Cheers,&lt;/P&gt;&lt;P&gt;Ram.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 17 Dec 2007 07:02:57 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/convert-to-local-currency-function/m-p/3206565#M764437</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-12-17T07:02:57Z</dc:date>
    </item>
    <item>
      <title>Re: CONVERT_TO_LOCAL_CURRENCY function</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/convert-to-local-currency-function/m-p/3206566#M764438</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Try using this Type..&lt;/P&gt;&lt;P&gt;  DATA: L_KURST     LIKE TCURR-KURST,  "exchg.rate ind.&lt;/P&gt;&lt;P&gt;        L_CURR_RATE LIKE TCURR-UKURS.  "exchange rate&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    CALL FUNCTION 'CONVERT_TO_LOCAL_CURRENCY'&lt;/P&gt;&lt;P&gt;         EXPORTING&lt;/P&gt;&lt;P&gt;              DATE             = P_CDATE        "currency date&lt;/P&gt;&lt;P&gt;              FOREIGN_AMOUNT   = TRN_AMT        "trans. currency amount&lt;/P&gt;&lt;P&gt;              FOREIGN_CURRENCY = TRN_CURR       "trans. currency code&lt;/P&gt;&lt;P&gt;              LOCAL_CURRENCY   = D_LOC_CURR     "local currency&lt;/P&gt;&lt;P&gt;              TYPE_OF_RATE     = L_KURST        "rate on key date&lt;/P&gt;&lt;P&gt;              RATE             = L_CURR_RATE "rate from tcurr&lt;/P&gt;&lt;P&gt;         IMPORTING&lt;/P&gt;&lt;P&gt;              EXCHANGE_RATE    = L_CURR_RATE&lt;/P&gt;&lt;P&gt;              FOREIGN_FACTOR   = TCURR-FFACT&lt;/P&gt;&lt;P&gt;              LOCAL_AMOUNT     = NEW_LOC_AMT&lt;/P&gt;&lt;P&gt;              LOCAL_FACTOR     = TCURR-TFACT&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>Mon, 17 Dec 2007 07:14:31 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/convert-to-local-currency-function/m-p/3206566#M764438</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-12-17T07:14:31Z</dc:date>
    </item>
    <item>
      <title>Re: CONVERT_TO_LOCAL_CURRENCY function</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/convert-to-local-currency-function/m-p/3206567#M764439</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Plese try this.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*If you get the error &lt;STRONG&gt;"No Rate Found"&lt;/STRONG&gt; then go to the &lt;STRONG&gt;tcode OB08&lt;/STRONG&gt;.*&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;This shows the existing currency exchange rates.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;If your Currency conversion doesn't exist enter the From and To values.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;*This should make the function module to work correctly.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*&lt;STRONG&gt;CALL FUNCTION 'CONVERT_TO_LOCAL_CURRENCY'&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;EXPORTING&lt;/P&gt;&lt;P&gt;DATE = sy-datum&lt;/P&gt;&lt;P&gt;FOREIGN_AMOUNT = '100'&lt;/P&gt;&lt;P&gt;FOREIGN_CURRENCY = 'US$'&lt;/P&gt;&lt;P&gt;LOCAL_CURRENCY = 'INR'&lt;/P&gt;&lt;P&gt;IMPORTING&lt;/P&gt;&lt;P&gt;EXCHANGE_RATE =&lt;/P&gt;&lt;P&gt;LOCAL_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;.&lt;/P&gt;&lt;P&gt;IF SY-SUBRC 0.&lt;/P&gt;&lt;P&gt;MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO&lt;/P&gt;&lt;P&gt;WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 17 Dec 2007 07:20:17 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/convert-to-local-currency-function/m-p/3206567#M764439</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-12-17T07:20:17Z</dc:date>
    </item>
    <item>
      <title>Re: CONVERT_TO_LOCAL_CURRENCY function</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/convert-to-local-currency-function/m-p/3206568#M764440</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Bach Mieu,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Check this out use this one...... &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can Use the Following Function Module to convert from one Currency vale to other&lt;/P&gt;&lt;P&gt;In following function module we need to pass Foreign currency, Local Currency type_rate:Type of rate M=Average rate  G=Bank buying rate B=bank selling rate&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;We Get Exchange rate for that day, foreign factor, Local factor.&lt;/P&gt;&lt;P&gt;And Foreign currency can be calculated as below mentioned in IF ENDIF&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: l_er TYPE tcurr-ukurs, &amp;amp;quot;&lt;/P&gt;&lt;P&gt;l_ff TYPE tcurr-ffact,&lt;/P&gt;&lt;P&gt;l_lf TYPE tcurr-tfact,&lt;/P&gt;&lt;P&gt;l_erate(12) TYPE c,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'READ_EXCHANGE_RATE'&lt;/P&gt;&lt;P&gt;EXPORTING&lt;/P&gt;&lt;P&gt;date = sy-datum&lt;/P&gt;&lt;P&gt;foreign_currency = wa_bseg-pswsl&lt;/P&gt;&lt;P&gt;local_currency = c_euro&lt;/P&gt;&lt;P&gt;type_of_rate = 'M'&lt;/P&gt;&lt;P&gt;IMPORTING&lt;/P&gt;&lt;P&gt;exchange_rate = l_er&lt;/P&gt;&lt;P&gt;foreign_factor = l_ff&lt;/P&gt;&lt;P&gt;local_factor = l_lf&lt;/P&gt;&lt;P&gt;EXCEPTIONS&lt;/P&gt;&lt;P&gt;no_rate_found = 1&lt;/P&gt;&lt;P&gt;no_factors_found = 2&lt;/P&gt;&lt;P&gt;no_spread_found = 3&lt;/P&gt;&lt;P&gt;derived_2_times = 4&lt;/P&gt;&lt;P&gt;overflow = 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;l_erate = l_er / ( l_ff / l_lf ).&lt;/P&gt;&lt;P&gt;wa_itab-wrbtr = wa_itab-wrbtr * l_erate.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;May be ur given exchange rate is not valid..... give the correct exchange rate... &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this may help you...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Reward if useful&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards,&lt;/P&gt;&lt;P&gt;sunil kairam.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 17 Dec 2007 07:22:02 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/convert-to-local-currency-function/m-p/3206568#M764440</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-12-17T07:22:02Z</dc:date>
    </item>
    <item>
      <title>Re: CONVERT_TO_LOCAL_CURRENCY function</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/convert-to-local-currency-function/m-p/3206569#M764441</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;What is the type you are using for it_item-kursf? This should be of type TCURR-UKURS.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Sriram Ponna.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 17 Dec 2007 07:24:36 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/convert-to-local-currency-function/m-p/3206569#M764441</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-12-17T07:24:36Z</dc:date>
    </item>
    <item>
      <title>Re: CONVERT_TO_LOCAL_CURRENCY function</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/convert-to-local-currency-function/m-p/3206570#M764442</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks for all,&lt;/P&gt;&lt;P&gt;But when I execute function CONVERT_TO_FOREIGN_CURRENCY as:&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             = it_item-budat&lt;/P&gt;&lt;P&gt;              foreign_currency = it_item-waerk&lt;/P&gt;&lt;P&gt;              local_amount     = it_item-dmbtr&lt;/P&gt;&lt;P&gt;              local_currency   = it_item-waers&lt;/P&gt;&lt;P&gt;            IMPORTING&lt;/P&gt;&lt;P&gt;              exchange_rate    = it_item-kursf  "Exchange rate&lt;/P&gt;&lt;P&gt;              foreign_amount   = it_item-wrbtr. "Tax Amount(Document)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Don't have any error.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 17 Dec 2007 07:33:01 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/convert-to-local-currency-function/m-p/3206570#M764442</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-12-17T07:33:01Z</dc:date>
    </item>
  </channel>
</rss>

