Download as pdf or txt
Download as pdf or txt
You are on page 1of 2

CONVERT_DECFLOAT_TO_CURR SAP Method - Conversion

from type DECFLOAT to CURR


se80.co.uk/oo-abap/c/cl_a/cl_abap_decfloat-convert_decfloat_to_curr.htm

ABAP OO Class Methods

Below is documentation, parameters and attributes of ABAP Method


CONVERT_DECFLOAT_TO_CURR within SAP class CL_ABAP_DECFLOAT. There is also a
number of example ABAP code snipts to help you implement this method.

This method is available within SAP systems depending on your version and release level
and you can view further information by entering the class name CL_ABAP_DECFLOAT into
relevant SAP transactions such as SE24 or SE80, and then selecting the method you are
interested in. Also check out the Contribute below to view or add related hints, tips, example
screen shots and any other information.

Class: CL_ABAP_DECFLOAT

Method: CONVERT_DECFLOAT_TO_CURR

Method Type: Static Method


This is a Static Method so you can call it directly

Importing Parameters:
Below is a list of importing parameters associated with this method, including its name,
description and data type

AMOUNT_DECFLOAT " Amount (Type DECFLOAT34) TYPE DECFLOAT


CUKY " Non-ISO-Currency Key TYPE SYCURR

Exporting Parameters:
AMOUNT_CURR " Amount (DDIC Type CURR) TYPE P
ROUNDED " Amount had to be rounded TYPE ABAP_BOOL

Exceptions:
CX_SY_CONVERSION_OVERFLOW - System Exception for Overflow When Converting

Example ABAP coding

DATA:

1/2
ld_AMOUNT_DECFLOAT TYPE DECFLOAT ,
ld_CUKY TYPE SYCURR ,
ld_AMOUNT_CURR TYPE P ,
ld_ROUNDED TYPE ABAP_BOOL.

" ld_AMOUNT_DECFLOAT = "


" ld_CUKY = "
CALL METHOD CL_ABAP_DECFLOAT=>CONVERT_DECFLOAT_TO_CURR(
EXPORTING
AMOUNT_DECFLOAT = ld_AMOUNT_DECFLOAT
CUKY = ld_CUKY
IMPORTING
AMOUNT_CURR = ld_AMOUNT_CURR
ROUNDED = ld_ROUNDED

EXCEPTIONS
CX_SY_CONVERSION_OVERFLOW = 1 ).

2/2

You might also like