‎2010 Apr 12 11:46 AM
Hello Experts,
Please resolve my Problem......
As i am Working on 4.7, Here i am facing one problem, in my report i am getting vendor closing balance and vendor opening balance through function BAPI_AP_ACC_GETKEYDATEBALANCE. Here after executing this function i am getting output like:
keybalance-T_CURR_BAL = 17500.0000.
when i am passing this value to my temp variable which is like bseg-dmbtr i am getting 1750000.00
But now user requirement is user only wants 2 digits after decimal like 17500.00. I am unable to get this value kindly resolve my problem.
Regards
Shelly Malik
‎2010 Apr 12 11:49 AM
Hi,
you should use an intermediary variable for this like
data new_var(8) type p decimals 2.
keybalance-T_CURR_BAL = 17500.0000
move keybalance-T_CURR_BAL to new_var
move new_var to temp variable.
‎2010 Apr 12 11:54 AM
Hi,
Still it is Doing same thing.....
keybalance-T_CURR_BAL = 17500.0000.
vtemp = 1750000.00.
where vtemp is like p(16) decimal 2.
‎2010 Apr 12 11:57 AM
dear,
you can take one global variable like
data: gv_var type p decimals 2.
and assign the value which you are getting after bapi to this variable.
now you will get only two digits after decimal.
regards.
Srinivas
‎2010 Apr 12 11:59 AM
Check Program attributes, Fixed Point Arithmetic should be set to true.
Regards
Vinod
‎2010 Apr 12 12:13 PM