2008 Jun 06 9:55 AM
2008 Jun 06 10:00 AM
hi,
used for Conversion of material units
Ensure same Material UOM for quantity comparison as follows
CALL FUNCTION 'MD_CONVERT_MATERIAL_UNIT'
EXPORTING
i_matnr = l_matnr
i_in_me = l_meins_in
i_out_me = 'KG'
i_menge = l_gsmng
IMPORTING
e_menge = l_gsmng
EXCEPTIONS
error_in_application = 1
error = 2
OTHERS = 3.
IF sy-subrc <> 0.
WRITE:/ 'Material Unit conversion not maintained for ',
wa_tab-cell_0002.
regards
mahesh
2008 Jun 06 9:59 AM
Hi,
This FM is used for Conversion of material units.
e.g.
CALL FUNCTION 'MD_CONVERT_MATERIAL_UNIT'
EXPORTING
i_matnr = l_matnr
i_in_me = l_meins_in
i_out_me = 'KG'
i_menge = l_gsmng
IMPORTING
e_menge = l_gsmng
EXCEPTIONS
error_in_application = 1
error = 2
OTHERS = 3.
You can also use FM MATERIAL_UNIT_CONVERSION
Some other FM are
CF_UT_UNIT_CONVERSION Converts material unit quantities
MATERIAL_UNIT_CONVERSION Converts base unit to alternative unit
UNIT_CONVERSION_SIMPLE Converts measurement unit values and rounds
2008 Jun 06 10:00 AM
hi,
used for Conversion of material units
Ensure same Material UOM for quantity comparison as follows
CALL FUNCTION 'MD_CONVERT_MATERIAL_UNIT'
EXPORTING
i_matnr = l_matnr
i_in_me = l_meins_in
i_out_me = 'KG'
i_menge = l_gsmng
IMPORTING
e_menge = l_gsmng
EXCEPTIONS
error_in_application = 1
error = 2
OTHERS = 3.
IF sy-subrc <> 0.
WRITE:/ 'Material Unit conversion not maintained for ',
wa_tab-cell_0002.
regards
mahesh
2008 Jun 06 10:22 AM
Hi sri with FM all u need to give is the quantity in one Unit of measure and give the target unit... it will automatically take the convertion factor and give you the output..
1 kg = X pounds.
if you give 1 and kg and pounds as input it will give you the X.