cancel
Showing results for 
Search instead for 
Did you mean: 

FM "SPELL AMOUNT " dosnt give the actual result , plz look in2 this

Former Member
0 Kudos

Hello

i m using FM "SPELL_AMOUNT"

CALL FUNCTION 'SPELL_AMOUNT'

EXPORTING

AMOUNT = TOT

CURRENCY = VBAK-WAERK

  • FILLER = ' '

LANGUAGE = SY-LANGU

IMPORTING

IN_WORDS = WORD

EXCEPTIONS

NOT_FOUND = 1

TOO_LARGE = 2

OTHERS = 3

.

IF SY-SUBRC <> 0.

  • MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO

  • WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.

ENDIF.

T_ADRS-TOT_WORDS = WORD-WORD.

But it doesnt give the correct result(considers the whole nos including digits after decim point) , any way out

Thnx Moni

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi,

Have you tried splitting your amount at '.', calling the function twice for both amounts before and after demical, and then concatenating the results.

Please elaborate your input and desired output if I haven't understood the problem correctly.

Regards

Former Member
0 Kudos

Hi Khan Saab

For Amount 121000.00 it dispalys "One million One Hundred thousands "

I have not used SPLIT . Can u send some sample code plz

Thnx

Moni

Message was edited by: md monirujjaman

athavanraja
Active Contributor
0 Kudos

Which currency you are using.

I have tried with USD and INR and got the following result in both the cases.

ONE HUNDRED TWENTY-ONE THOUSAND

even with

121000.00 is the same result

Regards

Raja

Message was edited by: Durairaj Athavan Raja

Former Member
0 Kudos

solved ,sorry i didnt pass the Currency value .

Former Member
0 Kudos

Hi Moni,

Good to know that your problem is resolved. Could you please mark the thread as answered.

Regards,

Anand Mandlika.

Answers (0)