C# DateTime FromOADate
Description
DateTime FromOADate
returns a DateTime equivalent to
the specified OLE Automation Date.
Syntax
DateTime.FromOADate
has the following syntax.
public static DateTime FromOADate(
double d
)
Parameters
DateTime.FromOADate
has the following parameters.
d
- An OLE Automation Date value.
Returns
DateTime.FromOADate
method returns An object that represents the same date and time as d.
Example
Returns a DateTime equivalent to the specified OLE Automation Date.
using System;/*from w w w.j a v a2 s.c om*/
public class MainClass{
public static void Main(String[] argv){
DateTime dt = DateTime.FromFileTimeUtc(12123123123L);
System.Console.WriteLine(dt);
}
}
The code above generates the following result.