NGWS SDK Documentation  

This is preliminary documentation and subject to change.
To comment on this topic, please send us email at ngwssdk@microsoft.com. Thanks!

Decimal.Subtract

Subtracts two specified Decimal values.

[Visual Basic]
Public Shared Function Subtract( _
   ByVal d1 As Decimal, _
   ByVal d2 As Decimal _
) As Decimal
[C#]
public static Decimal Subtract(
   Decimal d1,
   Decimal d2
);
[C++]
public: static Decimal Subtract(
   Decimal d1,
   Decimal d2
);
[JScript]
public static function Subtract(
   d1 : Decimal,
   d2 : Decimal
) : Decimal;

Parameters

d1
The left operand, a Decimal.
d2
The right operand, a Decimal.

Return Value

The result of subtracting two Decimal values.

Exceptions

Exception Type Condition
OverflowException is thrown if result is too large to represent as a Decimal.

Remarks

The method result's of evaluating the first decimal minus the second decimal.

The Subtaction method performs an arithmetic function by subtracting two Decimal values (d1- d) and returns the result of the operation.

See Also

Decimal Structure | Decimal Members | System Namespace