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!

DateTime Addition Operator

Adds a TimeSpan value to a DateTime value.

[C#]
public static DateTime operator +(
   DateTime d,
   TimeSpan t
);
[C++]
public: static DateTime operator op_Addition(
   DateTime d,
   TimeSpan t
);
[JScript]
returnValue = d + t;

[Visual Basic] In Visual Basic, you cannot use the operators defined by a type, nor override them or define your own.

[JScript] In JScript, you can use the operators defined by a type, but you cannot override them or define your own.

Arguments [JScript]

d
A DateTime value.
t
A TimeSpan value.

Parameters [C#, C++]

d
A DateTime value.
t
A TimeSpan value.

Return Value [C#, C++, JScript]

A DateTime sum of adding a DateTime and a TimSpan value.

Remarks [C#, C++, JScript]

This operator takes a DateTime value and a TimeSpan value and adds them together (d + t), so that the sum has a tick value equal to the sum of the tick values. The sum is formatted as a DateTime value.

See Also

DateTime Structure | DateTime Members | System Namespace | TimeSpan | Ticks