System.TimeSpan.op_UnaryNegation Method

Returns a TimeSpan whose value is the negated value of the specified instance.

Syntax

public static TimeSpan operator- (TimeSpan t)

Parameters

t
The time interval to be negated.

Returns

An object that has the same numeric value as this instance, but the opposite sign.

Exceptions

TypeReason
OverflowException t equals TimeSpan.MinValue.

Remarks

Documentation for this section has not yet been entered.

Requirements

Namespace: System
Assembly: mscorlib (in mscorlib.dll)
Assembly Versions: 1.0.5000.0, 2.0.0.0, 4.0.0.0