J JDS Active Member Licensed User Longtime User Aug 23, 2019 #1 At the beginning of the app the time is correct. Then at a certain point the time is two (2) hours earlier. I can't find the moment when this happens. Is there a way/command which changes the default time? B4X: Sub GetTime As String Dim lNow As Long lNow = DateTime.Now Return DateTime.Time(lNow) End Sub I use the above code to generate the time-string.
At the beginning of the app the time is correct. Then at a certain point the time is two (2) hours earlier. I can't find the moment when this happens. Is there a way/command which changes the default time? B4X: Sub GetTime As String Dim lNow As Long lNow = DateTime.Now Return DateTime.Time(lNow) End Sub I use the above code to generate the time-string.
E emexes Expert Licensed User Longtime User Aug 23, 2019 #2 JDS said: Then at a certain point the time is two (2) hours earlier. Click to expand... Say what?!?! Are you manipulating the time zone at all? Perhaps log the timezone too (time format character Z, I think). Or set up a timer tick that checks and updates a global time_at_last_tick Long variable, and Logs the last time and current time if time goes backwards. Upvote 0
JDS said: Then at a certain point the time is two (2) hours earlier. Click to expand... Say what?!?! Are you manipulating the time zone at all? Perhaps log the timezone too (time format character Z, I think). Or set up a timer tick that checks and updates a global time_at_last_tick Long variable, and Logs the last time and current time if time goes backwards.