Brian Dunning's FileMaker Custom Functions

NumberInWords ( NumberIn ; Currency ; DecimalCurr )

Convert Number to Words, including currency terms.

  Average rating: 3.9 (42 votes) Log in to vote

Chris Harvey   Chris Harvey
Bank of Bermuda
http://www.bankofbermuda.bm

Share on Facebook Share on Twitter

  Sample input:
61915.21
  Sample output:
Sixty One Thousand Nine Hundred Fifteen Dollars and Twenty One Cents

  Function definition: (Copy & paste into FileMaker's Edit Custom Function window)

This should work for most currencies, or even other units such as gallons or litres, etc. Give a null value for Currency if you don't want one. If you want the decimal part to be ignored, set Decimalcurr to "None".
In it's current form this function will handle values into the Trillions. As it works recursively, you can change the Out of Range check value and the names in one Choose function to extend it. It can also handle British Billions by changing the one Choose list.

 

Comments

krishna   krishna, Bnagalore
Jun 7, 2016
Hello,

Kindly help me how can above custom function can be used to convert number to words in vtiget invoice /sales orders.

Regards,
Krishnaprasad PB
 
Philip McGeehan   Philip McGeehan, SMD Ltd
Jul 5, 2016
You need FileMaker Pro Advanced to create a new custom function called NumberInWords with the parameters: "NumberIn"; "Currency"; and "DecimalCurr"; and the calculation as above.

Then you can create a new calculation field as text in your invoice/sales orders table with the calculation:
NumberInWords ( YOURNUMBERFIELD ; "pounds" ; "pence" )

Change the YOURNUMBERFIELD text to the field name where your number you want to convert is.
 
Seamus Berkeley   Seamus Berkeley, Taos
Dec 22, 2016
Thanks so much for this custom function, Chris—works super!

Just one minor edit: the text "Four" has an added space at the end of the word (as written "Four "). Just removed that space in two places and now result has no double spacing.
 

Log in to post comments.

 

Note: these functions are not guaranteed or supported by BrianDunning.com. Please contact the individual developer with any questions or problems.

Under construction. Email me your wish list for improvements.