CY Function
Last modified: March 09, 2015
Applies to: Office 2013 | Visio 2013
In this article
Syntax
Remarks
Example 1
Example 2
Example 3
Example 4
Returns a currency value.
CY(value, cyID)
Parameters
|
Name |
Required/Optional |
Data Type |
Description |
|---|---|---|---|
|
value |
Optional |
Number or String |
A number or a string that includes currency-specific formatting. If not specified, the currency value is formatted according to the currency style in the system's Region and Language settings. |
|
cyID |
Optional |
Number |
A numeric currency ID or a three-character quoted string for the ISO 4217 abbreviation. |
To specify a different currency, you must include a valid cyID. For a list, see About currency constants.
If value is incompatible with the designated currency type, or if an invalid argument such as "not a number" is specified, a #VALUE! error is returned. If value is greater than 922,337,203,685,477.5807 or less than -922,337,203,685,477.5808, a #VALUE! error is returned.
For better precision with very large currency values that include fractions of a unit, such as 3.6 trillion, use string arguments for value.
Specifying an invalid cyID returns an error.