NUMBERASWORDS Function: Difference between revisions
From Planfix
No edit summary |
|||
| (One intermediate revision by the same user not shown) | |||
| Line 38: | Line 38: | ||
To display a number as words in a document, use the following function: | To display a number as words in a document, use the following function: | ||
<div style="display: block; padding: 1em; margin: 0 0 10px; font-size: 13px; line-height: 1.65; color: black; word-wrap: break-word; background-color: #f9f9f9; border: 1px solid #ddd; border-radius: 4px;"> | <div style="display: block; padding: 1em; margin: 0 0 10px; font-size: 13px; line-height: 1.65; color: black; word-wrap: break-word; background-color: #f9f9f9; border: 1px solid #ddd; border-radius: 4px;"> | ||
<nowiki>NUMBERASWORDS(SUM({{DataTag.Service.Cost}}*{{DataTag.Service.Quantity}}); 2; "en")</nowiki> | <nowiki>NUMBERASWORDS(SUM({{DataTag.Service.Cost}}*{{DataTag.Service.Quantity}}); 2; "en")</nowiki></div> | ||
== Go To == | == Go To == | ||
*[[Standard functions]] | *[[Standard functions]] | ||
Latest revision as of 12:15, 26 November 2025
The NUMBERASWORDS function
This is a function that returns a number as words. Only the integer part of the number is written out.
Format:
NUMBERASWORDS(number; Output; "language")
Where:
- number — is a number or formula
- Output — defines how the numeral will be displayed (from 0 to 6)
- language — string that specifies the output language. If left empty (""), the language of the user generating the document is used.
Languages and their Output methods:
- English ("en")
- 0-3 — default (cardinal number)
- 4-6 — capitalized default
- German ("de")
- 0 — default (gender-neutral)
- 1 — written in feminine
- 2 — written in masculine
- 3 — written in neuter
- 4 — capitalized in feminine
- 5 — capitalized in masculine
- 6 — capitalized in neuter
- French ("fr")
- 0 — default (cardinal number)
- 1 — written in feminine
- 2 — written in masculine
- 4 — capitalized in feminine
- 5 — capitalized in masculine
Example
To display a number as words in a document, use the following function:
NUMBERASWORDS(SUM({{DataTag.Service.Cost}}*{{DataTag.Service.Quantity}}); 2; "en")