Converts the value of this DateTime to the format of the local system file time.
[Visual Basic] Public Function ToFileTime() As Long [C#] public long ToFileTime(); [C++] public: __int64 ToFileTime(); [JScript] public function ToFileTime() : long;
Returns the value of this DateTime in the format of the local system file time.
Exception Type | Condition |
---|---|
ArgumentOutOfRangeException | If this DateTime contains a value that cannot be converted to a system file time. |
A system file time is an unsigned 8-byte value representing the date and time as the number of 100-nanosecond intervals that have elapsed since 1/1/1601 12:00 AM.
Dates that are earlier than 01/01/1601 12:00:00 AM UTC cannot be converted to a local system file time value, and an exception will be thrown.
DateTime Structure | DateTime Members | System Namespace | Int64 | ToUniversalTime | System.DirectoryServices.IADsPropertyValue.UTCTime