Shopping Cart

Search:

Signup

Contact

FileMaker is a registered trademark of FileMaker, Inc. in the U.S. and other countries.

# FileMaker Pro Custom Functions

NumText ( theNumber ; CurrSymbol ; Separator ; Decimal)

Rate this function:

Discuss this Custom Function

Matt Wills, Virtual Vermont
http://www.virtualvermont.com/FMP/

Converts number to formatted text equivalent

Sample Input:
 NumText (123456.78 ; "\$" "," ; ".") Numtext (123456789 ; "" ; "," ; "")
Sample Output:
 \$123,456.78 123,456,789

Then copy & paste into FileMaker Advanced's Edit Custom Function window.

## Description:

Converts a number to its formatted text equivalent.

Expands on Jeremiah Small's AddDollarFormat cf, with these differences:

-Accommodates up to Billions;
-Retains the decimal portion of the original number;
-Allows user to decide whether to include currency notation.

CurrSymbol: the desired currency symbol.

Separator: the desired thousands separator. Defaults to comma if left blank.

Decimal: the desired symbol for decimal separator. Decimal portion of number is DROPPED if left blank.

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

This is my Custom Function and I want to edit it

## Discuss:

I had to modify this as I required to always have 2 places of decimals.

See below

R =
Substitute ( If ( not IsEmpty ( Decimal ) ;
Case (
theNumber - Int ( theNumber ) > 0 and Length ( theNumber - Int ( theNumber ) ) ≥ 3; theNumber - Int ( theNumber );
theNumber - Int ( theNumber ) > 0 and Length ( theNumber - Int ( theNumber ) ) = 2; theNumber - Int ( theNumber ) & "0";

".00");

""); "."; Decimal )

It still saved me some time so thanks a lot...

Ken Barker, Wexford/Ireland
February 19, 2013 7:55am