BsonUtilsToUniversalTime Method |
Converts a DateTime to UTC (with special handling for MinValue and MaxValue).
Namespace:
MongoDB.Bson
Assembly:
MongoDB.Bson (in MongoDB.Bson.dll) Version: 2.10.0+569905ff5e778c38ea19d9d0392496a83e1704ed
Syntax public static DateTime ToUniversalTime(
DateTime dateTime
)
Public Shared Function ToUniversalTime (
dateTime As DateTime
) As DateTime
static member ToUniversalTime :
dateTime : DateTime -> DateTime
Parameters
- dateTime
- Type: SystemDateTime
A DateTime.
Return Value
Type:
DateTimeThe DateTime in UTC.
See Also