In french: NombreEnLettres
Converts a number to words.
The result of the conversion is:
- expressed in French if the runtime language of the application is French. If the language of the operating system is Belgium, the "septante", "quatre-vingts" and "nonante" notations will be used.
- expressed in English in all the other cases.
// Displays "eighty three point thirty four"
// Displays "one Euro ten"
Info(NumberInWords(1.01, "dollar(s)", "cent(s)"))
// Displays "one dollar and one cent"
<Result> = NumberInWords(<Number to convert> [, <Unit> [, <Name of hundredths>]])
<Result>: Character string
<Number to convert>: Currency
Number to convert to a character string. The number to convert to words has the following characteristics:
- 23 significant digits: up to 17 digits for the integer part, up to 6 digits for the decimal part.
- can be included in the interval for defining the currencies: between -604 462 909 807 314 587,353 087 and +604 462 909 807 314 587,353 087.
<Unit>: Optional character string
Unit to be used in the result: Dollars, Euros, ... You can add an "s" in brackets (e.g., "(s)") if the currency can be pluralized.
If this parameter is not specified, the following string will be used:
- "comma" in French: for example: "ten comma twenty-five".
- "point" in English: for example: "ten point twenty-five".
<Name of hundredths>: Optional character string
Name of the hundredths that will be used in the result. You can add an "s" in brackets (e.g., "(s)") if the hundredths can be pluralized.
- The decimal part is rounded to 2 digits.
- In English, the large numbers use the American rules:
(Power of 10)
|Unit used in French||Unit used in English (American)|
|10 power 6||million||million|
|10 power 9||milliard||billion|
|10 power 12||billion||quintillion|
|10 power 15||billiard||quadrillion|
Unit examples (WINDEV): The NumberInWords function
[ + ]
Using the WLanguage NumberInWords function.
This function is used to convert a numeric into words, which is very useful to automatically fill a check for example.
Business / UI classification: Neutral code
This page is also available for…