PARSEDECIMAL

Returns the decimal value of the object passed to the function.

Syntax

= PARSEDECIMAL(value)

Parameters

value

A number whose decimal value is to be determined.  The number can be specified as an integer (e.g., 37), a decimal value (e.g., 37.48), as a string, or as the value of a variable (e.g, UnitPrice).

Return Type

Decimal

Examples

Example

Returns

= PARSEDECIMAL(-3)

-3

= PARSEDECIMAL(3)

3

= PARSEDECIMAL(“$1,234”)

1234

= PARSEDECIMAL(“$-1,234.57”)

-1234.57

= PARSEDECIMAL(“98%”)

.98

= PARSEDECIMAL(UnitPrice)

The decimal value of the UnitPrice

= PARSEDECIMAL(“abcd”)

Displays message “ERROR: Input string was not in a correct format”