on 10-30-2008 9:22 AM
my form name is zretail_invoice.the field i want to convert is wa_final-gtotal.i want this to be converted the value in gtotal to words.
how to do in smartforms by using function module
spell_amount
hr_chg_in_words
in steps please...
same reply
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
This is discussed many times in ABAP forum and Form printing. Please search before posting any Question.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi
Check this:
DATA : T_SPELL LIKE SPELL,
V_TOTAL TYPE p decimals 2 VALUE '1985.64'.
DATA : PAMOUNT TYPE p decimals 2 .
PAMOUNT = V_TOTAL.
PERFORM SPELL_AMOUNT USING PAMOUNT.
*WRITE: T_SPELL-WORD, 'and', T_SPELL-DECWORD.
FORM SPELL_AMOUNT USING AMOUNT.
data : l_num type SPELL-NUMBER.
l_num = amount.
CALL FUNCTION 'SPELL_AMOUNT'
EXPORTING
AMOUNT = l_num
*CURRENCY =
FILLER = SPACE
LANGUAGE = 'E'
IMPORTING
IN_WORDS = T_SPELL
EXCEPTIONS
NOT_FOUND = 1
TOO_LARGE = 2
OTHERS = 3.
write : T_SPELL-WORD.
l_num = ( amount * 100 ) mod 100.
CALL FUNCTION 'SPELL_AMOUNT'
EXPORTING
AMOUNT = l_num
*CURRENCY =
FILLER = SPACE
LANGUAGE = 'E'
IMPORTING
IN_WORDS = T_SPELL
EXCEPTIONS
NOT_FOUND = 1
TOO_LARGE = 2
OTHERS = 3.
write : T_SPELL-WORD.
ENDFORM. "SPELL_AMOUNT
Regards,
Vishwa.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
85 | |
10 | |
10 | |
9 | |
7 | |
6 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.