问题
I am writing a c++ program to read DBF file of foxpro database .I stumbled upon this date time field of eight bytes.How can i interpret it ? Any help would be highly appreciated ?
回答1:
The value is a double
The integer part is the day since 1899/12/30
internal const double JulianDay_1899_12_30 = 2415019.0;
double d = theValue;
in c#
return DateTime.FromOADate(d - JulianDay_1899_12_30);
see http://msdn.microsoft.com/en-us/library/system.datetime.fromoadate.aspx
来源:https://stackoverflow.com/questions/23577409/how-can-i-interpret-foxpro-dbf-file-date-time-field-eight-byte-in-my-c-pro