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.ToInt16

Converts this instance into an Int16.

[Visual Basic]
Overridable Public Function ToInt16() As Short
[C#]
public virtual short ToInt16();
[C++]
public: virtual short ToInt16();
[JScript]
public function ToInt16() : Int16;

Return Value

The Int16 value for this instance.

Exceptions

Exception Type Condition
InvalidCastException If this DateTime is not an Int16 value.

Remarks

The ToInt16 method casts this DateTime instance into an Int16 value. An exception is thrown if this instance cannot be coerced into a 16-bit signed integer (short).

See Also

DateTime Structure | DateTime Members | System Namespace | Int16 | UInt16