numbers into word

# Thread: numbers into word

1. Senior Member
Join Date
Dec 1969
Posts
175

## numbers into word

How can I have numbers into word... I have the script to convert numbers without decimals into word. But How do I convert numbers to word with decimals. eg. I have this figure: 1234.60 I want it as One thousand two hundred and thirty four and cents sixty only. Please guide me...

2. Senior Member
Join Date
Dec 1969
Posts
96,118

## I have a demo...

...at http://www.ClearviewDesign.com/NEWBIE<BR><BR>It doesn&#039;t do the cents, but that&#039;s easy:<BR><BR>Just take the integer part first, call the function to get the words for the dollars. Then subtract the integer from the original number and multiply the result by 100 and round. That gives you the cents, and you call the routine again.<BR><BR>&#060;%<BR>cost = 1234.60<BR>dollars = Int( cost )<BR>cents = Round( 100 * ( cost - dollars ) )<BR>strCost = NumberToWords( dollars ) & " dollars and " & NumberToWords( cents ) & " cents only"<BR>%&#062;<BR><BR>I forget if that is the name of that function in my demo, but you can adjust as needed.<BR><BR>

#### Posting Permissions

• You may not post new threads
• You may not post replies
• You may not post attachments
• You may not edit your posts
•