The following js code in Chrome dev console.
new Date(1560780000000)
yields
Tue Jun 18 2019 00:00:00 GMT+1000 (Australian Eastern Standard Time)
however in c# on the same machine, this yields
new DateTime(1970, 1, 1).AddMilliseconds(1560780000000);
17/06/2019 14:00:00
Using
new DateTime(1970, 1, 1).ToLocalTime().AddMilliseconds(1560780000000);
yields
18/06/2019 01:00:00
The date is still out by an hour. I am trying to translate a JS date into a C# DateTime accurately. I can't change the signature of the method from DateTime, can anyone help?
KH