REPORT zunit_conversion .
data: lv_input type p DECIMALS 3 value '10000.000',
lv_output type p DECIMALS 3.
CALL FUNCTION 'UNIT_CONVERSION_SIMPLE'
EXPORTING
input = lv_input
UNIT_IN = 'LB'
UNIT_OUT = 'KG'
IMPORTING
OUTPUT = lv_output
EXCEPTIONS
CONVERSION_NOT_FOUND = 1
DIVISION_BY_ZERO = 2
INPUT_INVALID = 3
OUTPUT_INVALID = 4
OVERFLOW = 5
TYPE_INVALID = 6
UNITS_MISSING = 7
UNIT_IN_NOT_FOUND = 8
UNIT_OUT_NOT_FOUND = 9
OTHERS = 10.
write:/ lv_output.
Here you can find examples and sample programs related to ABAP Report Programs, ALV Grid/List Programs, BDC, HR ABAP, Function Modules, BAPIs, BADIs, Smartforms, SapScripts, etc.
Google Search - Blog...........
Showing posts with label function module fm UNIT_CONVERSION_SIMPLE. Show all posts
Showing posts with label function module fm UNIT_CONVERSION_SIMPLE. Show all posts
Subscribe to:
Posts (Atom)