I need the current Datetime minus myDate1 in seconds.
myDate1
DateTime myDate1 = new DateTime(1970, 1, 9, 0, 0, 00); DateTime myDate2 = DateTime.Now; T
You can use Subtract method:
Subtract
DateTime myDate1 = new DateTime(1970, 1, 9, 0, 0, 00); DateTime myDate2 = DateTime.Now; TimeSpan ts = myDate2.Subtract(myDate1); MessageBox.Show(ts.TotalSeconds.ToString());