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

Function Module to Convert Char Value to Float

Former Member
0 Likes
3,169

Hi ,

    Is there any Function Module to Convert Char value to Float ,I tried in google did not find proper solution, Please help .

Thanks,

Kumar.

1 REPLY 1
Read only

gouravkumar64
Active Contributor
0 Likes
1,130

Hi,Try with

DATA : lv_float TYPE float.

CALL FUNCTION 'HRCM_STRING_TO_AMOUNT_CONVERT'

   EXPORTING

     string                    = '1,000,444.00'

     DECIMAL_SEPARATOR         = '.'

     THOUSANDS_SEPARATOR       = ','

  IMPORTING

    BETRG                     = lv_float

  EXCEPTIONS

    CONVERT_ERROR             = 1

    OTHERS                    = 2.

     WRITE : lv_float.

Thanks

Gourav.