Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

MD_CONVERT_MATERIAL_UNIT

Former Member
0 Likes
9,300

Hi experts,

CALL FUNCTION 'MD_CONVERT_MATERIAL_UNIT'

EXPORTING

i_matnr = p_lv_matnr

i_in_me = p_lv_kmein

i_out_me = p_lv_meins

i_menge = lv_imenge

IMPORTING

e_menge = lv_emenge

EXCEPTIONS

error_in_application = 1

error = 2

OTHERS = 3.

i am using this function module in my smartform.i am exporting the following parameters

i_matnr = vbrp-matnr.

i_in_me = 'EA'(stands for each piece)

i_out_me = 'CS'(stands for case or crate)

i_menge = '100.00' "ekpo-fkimg(quantity)

and in importing parameter the variable lv_emenge contains the same value i.e '100.00' even after using the above function module.

please reply.

thanks in advance

regards

akmal

1 REPLY 1
Read only

Former Member
0 Likes
3,595

Hi

First goto SE37 and check the fun module

by entering the values of MATNR,FROM UNIT and TO UNIT and see the value coming out of it

after confirming the value then use it in the code with proper declaration of the all parameters

It should work

also see in the table T006 table

You can also check the other fun module for this conversion

UNIT_CONVERSION_SIMPLE

Regards

Anji