‎2007 Jan 24 12:09 PM
Hi
I have a requirement for converting amount into words based on given currency.
I have tried doing this using function module spell_amount, but it is not working.
Points will be rewarded to the helpful answers.
Its very urgent.
Regards
Haritha.
‎2007 Jan 24 12:11 PM
Hi Haritha,
Chek this program <b>RF_SPELL</b> with similar requirement
‎2007 Jan 24 12:13 PM
hi Haritha,
Check with <b>HR_IN_CHG_INR_WRDS</b>
data: words(100) type c.
call function 'HR_IN_CHG_INR_WRDS'
exporting
amt_in_num = '100000'
importing
amt_in_words = words.
write:/ words.
‎2007 Jan 24 12:14 PM
Hello Check this:
Use the Function Module SPELL_AMOUNT to convert the integer into text.
DATA v_int TYPE i VALUE '1000'.
DATA words LIKE SPELL.
CALL FUNCTION 'SPELL_AMOUNT'
EXPORTING
AMOUNT = v_int
LANGUAGE = SY-LANGU
IMPORTING
IN_WORDS = words
.
WRITE words-word.
Vasanth
‎2007 Jan 24 12:15 PM
Hi,
Use the Function module to convert the currency <b>CONVERT_TO_FOREIGN_CURRENCY</b>
to convert the Amount in words, look this link
http://www.geocities.com/victorav15/sapr3/abapfun.html
Regards
Sudheer
‎2007 Jan 24 12:15 PM
Hi haritha,
REPORT ZSPELL.
TABLES SPELL.
DATA : T_SPELL LIKE SPELL OCCURS 0 WITH HEADER LINE.
DATA : PAMOUNT LIKE SPELL-NUMBER VALUE '1234510'.
SY-TITLE = 'SPELLING NUMBER'.
PERFORM SPELL_AMOUNT USING PAMOUNT 'USD'.
WRITE: 'NUMBERS', T_SPELL-WORD, 'DECIMALS ', T_SPELL-DECWORD.
FORM SPELL_AMOUNT USING PWRBTR PWAERS.
CALL FUNCTION 'SPELL_AMOUNT'
EXPORTING
AMOUNT = PAMOUNT
CURRENCY = PWAERS
FILLER = SPACE
LANGUAGE = 'E'
IMPORTING
IN_WORDS = T_SPELL
EXCEPTIONS
NOT_FOUND = 1
TOO_LARGE = 2
OTHERS = 3.
ENDFORM. " SPELL_AMOUNT