pbojan / cryptocoins-desklet-windows

Windows Desklet/Widget/Gadget that displays the current price of more than 1500+ coins and their daily percent changes.
MIT License
36 stars 7 forks source link

Time on widget 1 hour out #4

Closed Maddo03 closed 3 years ago

Maddo03 commented 3 years ago

Have just setup v1.4 and have got it working correctly with the coins I want to monitor, however the date/time at the bottom of each widget is 1 hour slow. Have tried changing the localtime and utctime settings in the script but have been unsuccessful. Would you have any advice on adding time +1 hour?

pbojan commented 3 years ago

Hey @Maddo03, can you explain exactly how do you mean by one hour behind?

The date/time on the widget is about when the widget updated last. The time between updates is defined in e.g. https://github.com/pbojan/cryptocoins-desklet-windows/blob/master/pbojan/CryptoCoins/Bitcoin/Bitcoin.ini with the UpdateTime param. This is by default 30min so the time will always be in the past by max 30min unless you have changed that value.

If something is wrong with the Date Format you can play around with the GetTimezoneDiff function at https://github.com/pbojan/cryptocoins-desklet-windows/blob/master/pbojan/%40Resources/scripts/Helpers.lua e.g. adding +/- 3600 seconds there and see if that helps.