2007 Aug 07 5:33 AM
hai gurus can any one tell me the funciton modules to convert the character string into numeric string
regards
afzal
hai gurus can any one tell me the funciton modules to convert the character string into numeric string
regards
afzal
2007 Aug 07 5:37 AM
Hi afzal,
Declare a variable of type N.
Assign the values of character string to this new variable
Regards
Arun
2007 Aug 07 5:38 AM
2007 Aug 07 5:39 AM
Hi Mohammad,
Try this function module: CATS_ITS_MAKE_STRING_NUMERICAL
Regards,
Sukhee
2007 Aug 07 5:42 AM
Hii Afzal,
Try this code..
<b>CATCH SYSTEM-EXCEPTIONS conversion_errors = 1.
MOVE text TO amount.
ENDCATCH.
IF sy-subrc EQ 1.
*not numeric</b>
Or use this FM
<b>NUMERIC_CHECK</b>
It returns a char data type for values other than numeric
and a numc data type for numeric values.
Hope it helps you...
Regards,
Ashish
2007 Aug 07 5:43 AM
hi check with the following code,,,declare a variable of type string, and a number.
assign a numeric value to the string type variable and then perform any operation.
data: str type string,
num type i.
str = '10'.
num = str.
num = num * 5.
write: num.
Answer is 50....does that solve ur problem
also check with FM CONVERT_STRING_TO_INTEGER
reward if useful
regards
dinesh
2007 Aug 07 5:44 AM
you can check this fm
C14W_CHAR_NUMBER_CONVERSION
or
MOVE_CHAR_TO_NUM
regards
shiba dutta
| User | Count |
|---|---|
| 6 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |