2 个解决方案
#1
先用秒
QDateTime date;
date.setTime_t(xxxx);
QDateTime date;
date.setTime_t(xxxx);
#2
public static DateTime ConvertDateTime(double tickCount){ DateTime dt1970 = new DateTime(1970, 1, 1); return dt1970.AddMilliseconds(tickCount).ToLocalTime();}
#1
先用秒
QDateTime date;
date.setTime_t(xxxx);
QDateTime date;
date.setTime_t(xxxx);
#2
public static DateTime ConvertDateTime(double tickCount){ DateTime dt1970 = new DateTime(1970, 1, 1); return dt1970.AddMilliseconds(tickCount).ToLocalTime();}