i\'ve looking around how to do this and i found a lot of examples with complicated code. Im using this:
var time1 = new Date();
var time1ms= time1.getTime(ti
Note that in the getTimezoneOffset() returns a value in minutes, so if you want to use the lapse, you can correct it for the timezone difference like this:
lapse = new Date(difference);
tz_correction_minutes = new Date().getTimezoneOffset() - lapse.getTimezoneOffset();
lapse.setMinutes(offset_date.getMinutes() + tz_correction_minutes);
now you can do:
label.text(lapse.getDate()-1+' days and' +lapse.getHours()+':'+lapse.getMinutes()+':'+lapse.getSeconds());
to print out the time difference in human readable form