DateTimeWithZone.Subtraction Operator (DateTimeWithZone, DayTimeDuration)DateTimeWithZone.Subtraction Operator (DateTimeWithZone, DayTimeDuration)DateTimeWithZone::Subtraction Operator (DateTimeWithZone, DayTimeDuration)
Subtracts a DayTimeDurationDayTimeDurationDayTimeDuration from a DateTimeWithZoneDateTimeWithZoneDateTimeWithZone.
Syntax
Public Shared Operator -( _ dateTime As DateTimeWithZone, _ duration As DayTimeDuration _ ) As DateTimeWithZone
public static DateTimeWithZone operator -( DateTimeWithZone dateTime, DayTimeDuration duration )
public: static DateTimeWithZone operator -( DateTimeWithZone dateTime, DayTimeDuration duration )
Parameters
- dateTime
Type: XmlPrime.DateTimeWithZoneXmlPrime.DateTimeWithZoneXmlPrime::DateTimeWithZone
The DateTimeWithZoneDateTimeWithZoneDateTimeWithZone to subtract from.
- duration
Type: XmlPrime.DayTimeDurationXmlPrime.DayTimeDurationXmlPrime::DayTimeDuration
The DayTimeDurationDayTimeDurationDayTimeDuration to subtract.
Return Value
Type: XmlPrime.DateTimeWithZoneXmlPrime.DateTimeWithZoneXmlPrime::DateTimeWithZone
A DateTimeWithZoneDateTimeWithZoneDateTimeWithZone that is the result of subtracting duration from dateTime.
Exceptions
Exception | Condition |
OverflowExceptionOverflowExceptionOverflowException | An overflow error occurred. |