Abs()

Math::Abs(T) method

Returns the absolute value of the specified value.

template<class T> static T System::Math::Abs(T value)

Template parameters

ParameterDescription
TThe type of the value accepted by the method as an argument

Arguments

ParameterTypeDescription
valueTA value of arithmetic type

Return Value

The absolute value of value

Math::Abs(const Decimal&) method

Returns the absolute value of a value represented by the specified Decimal object.

static Decimal System::Math::Abs(const Decimal &d)

Arguments

ParameterTypeDescription
dconst Decimal&A Decimal object

Return Value

The Decimal object representing the absolute value of the value represented by value

See Also