C#: Get Number of Days Since the Epoch
Get the number of days since the Epoch date using .NET/C#

C#: Get Number of Days Since the Epoch
Get the number of days since the Epoch date.
public int TickCount() { // epoch date 1/1/1970 //return DateTime.Today.Ticks; TimeSpan span = DateTime.Today.Subtract(DateTime.Parse("01-Jan-1970")); return span.Days; }