Click or drag to resize

DateTimeExtensionsToDateTime Method

Converts Timestamp to DateTime while preserving the milliseconds of the nanosecond fraction. The method generates a dateTime object of as specified by the outputFormat param.

Namespace:  MFiles.VAF.Configuration
Assembly:  MFiles.VAF.Configuration (in MFiles.VAF.Configuration.dll) Version: 2.1.0.1 (2.1.0.1)
Syntax
C#
public static DateTime ToDateTime(
	this Timestamp timestamp,
	DateTimeKind outputFormat = DateTimeKind.Local
)

Parameters

timestamp
Type: Timestamp
The timestamp object to convert.
outputFormat (Optional)
Type: SystemDateTimeKind
Specifies what the timestamp locality is, local or utc.

Return Value

Type: DateTime
Converted date time in the specified output format locality.

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type Timestamp. When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).
See Also