Adds two Currency values.
[Visual Basic] Public Shared Function Add( _ ByVal c1 As Currency, _ ByVal c2 As Currency _ ) As Currency [C#] public static Currency Add( Currency c1, Currency c2 ); [C++] public: static Currency Add( Currency c1, Currency c2 ); [JScript] public static function Add( c1 : Currency, c2 : Currency ) : Currency;
The value is the sum of adding two Currency values (c1 + c2).
Exception Type | Condition |
---|---|
OverflowException | If the sum of the two values is too large to represent as a Currency. |
The Add method performs the arithmetic funtion of adding two specified Currency values (c1 + c2) and returning the sum. An OverflowException will be thrown if the sum is a value greater than MaxValue.