2006 Oct 03 1:53 PM
Hi,
I have the field for hours IMRG-RECDV and its type is Flot. For example the output for this is displayed as 6,776100000000000E+04.
here 6,776100000000000E+04 means 6.776110101010 and the output will be 67761.
Could anyone let me know how to do this conversion.
Regards,
Ram
Hi Ravi,
Thanks for the help and also let me know what should be the type we need to take for the display of the field. I want the output to be displayed as 67761.
2006 Oct 03 1:57 PM
2006 Oct 03 2:14 PM
Hi Ravi,
Thanks for the help and also let me know what should be the type we need to take for the display of the field. I want the output to be displayed as 67761.
2006 Oct 03 2:17 PM
Are you displaying this field in an alv?
Declare another field as char type with appropriate length.
and do like this
data: v_new(22).
write V_field to V_new exponent 0.
condense v_new.
write:/ v_new.
Regards,
Ravi
2006 Oct 03 1:59 PM
hi use this conversion,
CONVERSION_EXIT_ADPCT_OUTPUT
it will Calculation (123.12345) to display (123.12)
2006 Oct 03 1:59 PM
Hi
Try out these function Modules
CEVA_CONVERT_FLOAT_TO_CHAR
KKEK_CONVERT_FLOAT_TO_CURR
If helpful, Pls reward me points
Regards
Manas Ranjan Panda
2006 Oct 03 2:03 PM
hi,
data: v_f type f value 67761.
write v_f exponent 0 decimals 0.
now the output will be 67761.
Regards,
Sailaja.
2006 Oct 03 2:27 PM
Hi,
The output field component type is IMRc_RECDV. So while displaying this its giving as the same thing. So which component type i need to take for outputting this field after conversion.'
Regards,
Ram
2006 Oct 03 2:16 PM
hi,
Though the type is f, we get the output by using the formatting options along with write.
data: v_float type f value 67761.
write v_float exponent 0 decimals 0.exponent 0 makes the no as 67761.00000000
To get 67761, we have to give decimals 0 addition.
Regards,
Sailaja.
2006 Oct 03 3:05 PM
hi,
data: v_float type <b>IMRC_RECDV</b> value 67761.
write v_float exponent 0 decimals 0.
If you are displaying in ALV, check the post specified by RAVI.
Regards,
Sailaja.
| User | Count |
|---|---|
| 6 | |
| 3 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |