Convert FLTP to CURRENCY ?

Hi, we try implementing code in Transfer Rule the BI7, then is necesary convert to value from FLTP to CURRENCY in USD.
any can help in code, please ?
This is my last try in code :
DATA : ZPASO(30).
CALL FUNCTION 'FLTP_CHAR_CONVERSION'
      EXPORTING
        INPUT =  *SOURCE_FIELDS-/BIC/ZCGC_VLST* <-- this is my FLTP
      IMPORTING
        FLSTR = ZPASO.
SHIFT ZPASO LEFT DELETING LEADING SPACE .
     RESULT = ZPASO.
     CURRENCY = 'USD'.
RESULT --> IS WHERE RECIBE CONVERTION.
Thank you.

Hello Victor,
Please take a look at the example below:
report  z_dsc_10.
data: w_float  type f,
      w_packed type p decimals 2.
w_float = 1.
call function 'MURC_ROUND_FLOAT_TO_PACKED'
  exporting
    if_float                    = w_float
    if_significant_places       = 15
  importing
    ef_packed                   = w_packed
  exceptions
    overflow                    = 1
    others                      = 2.
if sy-subrc ne 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
*         WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
endif.
write: w_packed.
Hope it helps you.
Daniel.
Edited by: Daniel Carvalho on Jan 9, 2009 12:40 PM

Similar Messages

  • Function module for converting the foreign currency to words

    hi,
    can anybody tell me about the function module for converting the foreign currency to words format.
    Like 25.50 USD
    should be "Twenty Five Dollar & Fifty Sents."
    foreign currency can be anyone like USD, JPY, EUR etc.
    Regards
    Nitin Varshney

    Hi,
    Try using the FM SPELL_AMOUNT
    Check this wiki
    [SPELL_AMOUNT|https://wiki.sdn.sap.com/wiki/display/Snippets/SpelltheAmountenteredin+words]
    Regards
    Sarves

  • Alternate Exchange Rate Type Not Picked while converting from Document Currency to Group Currency

    Hello Gurus,
    We have setup an alternate Exchange Rate type MNB for rate M for the postings happening in Hungary. Local currency is HUF. Group currency is USD.
    If the document currency is, lets say, EUR, latest MNB rate is correctly picked up (EUR to HUF) and postings are correctly converted into local currency (HUF).
    Although, for the same document, when a group currency is being calculated (EUR to USD), exchange rate type M is being picked up. Same happens if  document currency is HUF. Even then, the conversion is based on exchange rate type M.
    Is this a normal SAP behavior? How to prevent/correct this? This is also throwing off balances when we check in FAGLB03 or BSEG values in local and group currencies. In OB22, we have local currency1 and local currency 2 setup with exchange rate type M and we may not want to make any changes there as it is setup at global level.
    Do we need to run any valuations after the fact? if so, how?
    Thank you for your inputs in advance.
    Regards,
    Sagar

    Hi,
    You mentioned that "in OB22, we have local currency1 and local currency 2 setup with exchange rate type M". Then, I'm wondering how MNB is picked up for the first local curr. conversion to HUF? It should be 'M' instead. There must be some settings in your instance for such behavior. Can you check that?
    Actually, Group Curr. conversion happens with the rate defined for 2nd Loc.Curr.in OB22 which is 'M' in your case. Therefore, all the transactions are converted with M instead of MNB.
    Since you can't change OB22 per global co.policy, the exch.rate defined in OBA7 will overrule OB22. However, you've to make sure it's set up for all doc.types which are affected and posted in different curr. than HUF.
    As a workaround, another thought would be to maintain the same conversion rate for both exch.rate types MNB & M, for eg. HUF > USD rate is the same both exch.rate type MNB & M. This way, you ensure all transactions are posted with correct exch.rate irrespective of whatever rate type is used.
    From business, & global org. perspective, I'm sure they are sending the 'M' exch.rates to all their sister concerns monthly, so they would like to consolidate results as per standard rate in their system. Then, why ,as a local company, would you like to fiddle with standard process? It's a management decision, please run them through again before going ahead.
    Thanks,
    Nirav

  • Currency INR convert in EURO currency in MIRO

    Hello MM Sapperu2019s,
    Let me know the reason from forum when I enter the tax code in MIRO autoamcaally the Currency INR convert in EURO currency. Please provide your inputs what could be the reason for this and how I can resolve this case.
    Cheers,
    Kumar.S

    HI,
    Because your main vendor has currency EURO so its coming there  and IN po your currecny will be EURO
    check vendor currency
    If you don want it thne
    do following
    in MIRO after execution before giveing PO number chnage currency to INR and enter and then give PO number it will not chnage then
    Regards
    Kailas Ugale
    Edited by: kailasugale on Feb 9, 2012 11:51 AM

  • Function module - convert to local currency

    Dear all,
    I need to use a function module to convert to local currency a document that has been posted in foreign currency, which function module can I use? I tried convert_to_local_currency but I dont get any output...
    Else I need a function module to reverse a GL document, which function module should I use?
    Thanks and best regards!

    Hi,
    Please use the following linke and see if this helps.
    Re: FI Reverse Document BAPI
    Regards
    K.R

  • FM for convert to local currency other than CONVERT_TO_LOCAL_CURRENCY

    Does anyone know any other FM which converts into local currency???
    But it should be other than CONVERT_TO_LOCAL_CURRENCY..

    Hi Ajay,
    Just you can check it out in SE37.
    CONVERT_TO_LOCAL_CURRENCY_N
    CONVERT_TO_LOCAL_CURRENCY_O.
    CONVERT_TO_FOREIGN_CURRENCY
    Chk this Link
    convert to local  currency
    Reward Points if Useful
    Regards
    Gokul

  • AP Account Analysis Report USD not converting to Functional Currency

    When I am running AccountAnalysis Report , USD not converting to SGD\
    08-JUN-09 3D NETWORKS SINGAPORE PTE TI10050729 Invoice Nonrecoverable GST Yes
    USD 8,395.36 8,395.36 530000844
    Regards,
    Ajit
    Edited by: Ajit Raut on Jul 27, 2009 8:10 PM

    Resolved,
    ==============================================
    Please find below notes;
    Not all reports are appropriate to run under MRC responsibility.
    The reports that do not have set of books as parameter cannot show thedata in reporting currency as
    sob is not supplied. So all such reportsnot having set of books parameter cannot be expected to show
    the outputin reporting currency.
    Refr to the document "Multiple Reporting Currencies in Oracle Applications"
    Appendix A: MRC Reporting Responsibilities:
    Section Request Groups (page A-8)
    Extract from the document:
    The predefined MRC request groups allow you to access only those reports
    and programs that are "appropriate" to run when using a reporting responsibility.
    Pre–defined MRC request groups are in the format MRC Programs <product code>.
    Payables
    =======
    The following reports are available in the MRC Programs AP request group:
    • Accounts Payable Trial Balance Report
    • Posted Invoice Register
    • Posted Payment Register
    • Posting Hold Report
    • Transaction Reconciliation Report
    • Journal with GL Details Report

  • Currency Conversion in BEX - Converting to Two currencies

    Hi,
    My requirement is to give the user the option of displaying currency in either EUR or USD in BEX / BO report.
    in other words to convert Document currencies amount to EUR or USD.
    I have created a currency translation type
    Exchange rate  = M
    Currency Tab -> Target Currency ->  target currency from variable OP_CURPR
    Time reference = Standard infoObject 0CALDAY.
    When I  try to run the report, the variable OP_CURPR  gives me all the currencies loaded but my actual requirement is to see only EUR or USD and I also noticed that if I do not have EUR / USD then I cannot convert it.
    how do I resolve this.
    thanks,
    Edited by: Bhat Vaidya on Mar 5, 2012 8:12 AM

    Hi,
    I have created a new variable and the result is the same. i.e the document currencies that I have are EUR and CNY. In the selection prompt, I get these same values. but not USD. so it means that I cannot convert to USD since its not in the document currency field.
    my source currency is source currency from data record
    thanks
    Bhat
    Edited by: Bhat Vaidya on Mar 5, 2012 8:47 AM
    Edited by: Bhat Vaidya on Mar 5, 2012 8:55 AM

  • Converting from a currency other than LC

    Hello,
    We have a customer application where we store not only amount in LC but also the amount in Invoice Currency ("IC").  For example, we invoice customers in a currency other than our company code's local currencies.  We have a requirement to convert actuals into USD and EUR by taking IC not LC.  I have created a new category for this ACTBUD and have gotten it working for LC.  I want to get it to work starting IC as the base currency.  All the documentation I have read says that BPC uses LC as the default for currency translation.
    Does anyone know if this can be changed?
    Thanks,
    Mark

    Here you go...we have four different reporting currencies:
    IC = invoice currency or document currency.
    LC = Local Currrency
    USD = USD or Group Currency
    EUR = Our EU users have requested that we also track Euros translated at budgetd rates.
    The below code translates LC, USD and EUR from IC for all categories but Actual.  Our actuals we get directly from our SAP system.  We created a new category called ActBud and then translate the other reporting currencies from IC.  It works pretty well.
    // FX Translation for any data in the Customer application
    // Added following line for performance
    *PROCESS_EACH_MEMBER=TIME
    *SELECT (%FX_RATES%, "[ID]", "RATE", "[GROUP] = 'FX RATE'")
    // Block 1 - Clear out any previously calculated USD and EUR values, for all categories but Actual.
    *XDIM_MEMBERSET DATASRC=COMPANY
    *XDIM_MEMBERSET RPTCURRENCY=USD,EUR,LC
    *XDIM_MEMBERSET INTCO=<ALL>
    *WHEN CATEGORY
    *IS <> "ACTUAL"
        *WHEN CUSTACCOUNT.RATETYPE
        *IS <> "NOTRANS"
            *REC(FACTOR=0)
        *ENDWHEN
    *ENDWHEN
    *COMMIT
    //Block 2 - Perform standard foreign currency translation, for all categories but Actual.
    *XDIM_MEMBERSET DATASRC=COMPANY
    *XDIM_MEMBERSET INTCO=<ALL>
    *XDIM_MEMBERSET RPTCURRENCY=IC
    *LOOKUP RATE
        *DIM RATESRC="RATECALC"
        *DIM RATE=CUSTACCOUNT.RATETYPE
        *DIM SOURCECURRENCY:INPUTCURRENCY=INVOICECURRENCY
        *DIM TARGETCURRENCY_LC:INPUTCURRENCY=ENTITY.CURRENCY
        *DIM TARGETCURRENCY_USD:INPUTCURRENCY="USD"
        *DIM TARGETCURRENCY_EUR:INPUTCURRENCY="EUR"
    *ENDLOOKUP
    //*XDIM_MAXMEMBERS TIME=1
    *WHEN CATEGORY
    *IS <> "ACTUAL"
        *WHEN CUSTACCOUNT.RATETYPE
        *IS "NOTRANS"
        *IS %FX_RATES%
            *REC(FACTOR=LOOKUP(SOURCECURRENCY)/LOOKUP(TARGETCURRENCY_USD),RPTCURRENCY="USD")
            *REC(FACTOR=LOOKUP(SOURCECURRENCY)/LOOKUP(TARGETCURRENCY_LC),RPTCURRENCY="LC")
            *WHEN ENTITY.EURO
                *IS "Y"
                *REC(FACTOR=LOOKUP(SOURCECURRENCY)/LOOKUP(TARGETCURRENCY_EUR),RPTCURRENCY="EUR")
            *ENDWHEN
        *ELSE
           *REC(RPTCURRENCY="USD")
           *REC(RPTCURRENCY="LC")
           *WHEN ENTITY.EURO
                *IS "Y"
                *REC(RPTCURRENCY="EUR")
            *ENDWHEN
        *ENDWHEN
    *ENDWHEN
    *COMMIT

  • Need Function Module for convertion of  Foreign currency to Indian currency

    hi friends,
    i need function module for converting amount from
    Foreign currency to Indian currency
    thanks

    hi Venkat,
    Please use the function module CONVERT_TO_LOCAL_CURRENCY
    <b><u>Sample code:</u></b>
          call function 'CONVERT_TO_LOCAL_CURRENCY'
            exporting
              date             = p_alv_tab-begda
              foreign_amount   = p_alv_tab-kkost_p_person
              foreign_currency = p_alv_tab-kwaer                 " foreign currency
              local_currency   = l_ev_waer                           " Indian currency
            importing
              local_amount     = p_alv_tab-kkost_p_person
            exceptions
              no_rate_found    = 1
              overflow         = 2
              no_factors_found = 3
              no_spread_found  = 4
              others           = 5.
    Hope this helps,
    Sajan Joseph.

  • CONVERT TO FOREIGN CURRENCY

    Hi all,
    I am using CONVERT_TO_FOREIGN_CURRENCY function module for converting
    local currency to foreign currency.
    I am converting from HUF to USD ,in this case it is giving the error like USD/HUF exchange rates are not maintaining.
    But in my system exchange rates are maintaining in TCURR table.
    Here i have one query,in  the table TCURR fcurr and tcurr fields are there
    in this fcurr(from currency) means HUF and tcurr(to currency) means USD (in my case right) in that case they are maintaining,
    but fcurr is USD and tcurr is HUF  in that case they are not maintaing,
    Please confirm this .
    regards,
    rakesh.

    Hi Raki,
    Check the below code and test, this is with ref to common sap function modules by william. i made modifications according to your currency.
    Data: xrate type f,
          famt type p,
          ffact type f,
          lfact type f.
    parameters:fcurr like TCURC-WAERS default 'USD',
               lcurr like TCURC-WAERS default 'HUF',
               lamt like eban-rlwrt. "can also write as lamt type p.
    CALL FUNCTION 'CONVERT_TO_FOREIGN_CURRENCY'
      EXPORTING
        DATE                    = sy-datum
        FOREIGN_CURRENCY        = fcurr
        LOCAL_AMOUNT            = lamt
        LOCAL_CURRENCY          = lcurr
    IMPORTING
       EXCHANGE_RATE           = xrate
       FOREIGN_AMOUNT          = famt
       FOREIGN_FACTOR          = ffact
       LOCAL_FACTOR            = lfact
    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.
    write:/ lamt, 'converted form', lcurr, 'to', fcurr, 'is:', famt.
    else.
    write:/ lamt, 'not converted'.
    ENDIF.
    Cheers!!
    VEnk@
    Edited by: Venkat Reddy on Nov 3, 2008 9:49 AM

  • PO: Tax amt to be convert into local currency for government declaration

    Dear All,
    I have this scenario where the Company currency and Vendor currency is in USD.
    Because of Domestic Purchase, so Tax/VAT is incurred.
    For my case, because company and vendor currency are both in USD, but when declare the tax to the government, we need to convert it into local National Currency which is SGD.
    Can your please advice if somewhere in SAP standard where i can enter the SGD rate or amount for the tax, or somewhere i can configure to make it auto determine the SGD rate and tax amount?
    Thank you very much,
    CW

    dear firned,
    you would try t-code  FBB1
    regards,

  • Convert from X currency to Y currency?

    Hi Experts,
    Am looking to convert some amount from X currency to Y currency........so, am using the FM 'CONVERT_TO_LOCAL_CURRENCY'.........and in my  z prog. its working fine.
    but, still, i wanna to cross test the values in SE37 for the same FM, but, I am not getting any RETURN values!!!!!!!!
    1 - so, let me know, why am ´not getting the return values in se37? while in my z prog, its fine.
    2 - is there any other GOOD function module to achieve this?
    replies appreciated
    thanq

    Hello,
    See this: Currency conversion.
    Regards.

  • FM in order to convert values between currency

    Hi,
    I need a FM in order to convert a value from one currency to another.
    For example:
    value 12,54
    currency1 = EUR
    currency2= USD

    Hi
    What is the function module to convert currency?
    Re: EUR Conversion to USD
    Regards
    Pavan

  • Converting fltp

    hi experts
    i need to convert ausp-atflv that it data-type is fltp into a date data-type dats
    the field for convert looks like that 2.0080801000000000E+07
    thanks
    Amit

    DATA: lf like ausp-atflv VALUE '2.0080801000000000E+07',
          ln TYPE n LENGTH 8,
          ld TYPE dats.
    ln = lf.
    ld = ln.
    WRITE: / lf, ln, ld DD/MM/YYYY.

Maybe you are looking for