C#获取当前时间戳

TimeSpan tss = DateTime.UtcNow - new DateTime(1970, 1, 1, 0, 0, 0, 0);
long a = Convert.ToInt64(tss.TotalMilliseconds);

 

你可能感兴趣的:(C#获取当前时间戳)