sachaMONDE
Posts: 1
Joined: Mon Mar 29, 2021 1:31 pm

Timezone Incorrect

Hi, i tried to set the timezone to 'Europe/Paris' using moment.js but it does not work as expected, at every attempt i miss 2 hours and all my shedule is wrong because of it.
i make :
HGantt.setOptions({
time: {
timezone: 'Europe/Paris'
}
});

and when i try :
console.log(
'Current time in Paris',
HGantt.time.dateFormat('%Y-%m-%d %H:%M:%S', Date.now())

i got this output : Current time in Paris 2021-03-29 13:34:34 (but actualy its 15:34.34)

Can somebody have an explanantion ? did i use it wrong ?
dominik.c
Posts: 2081
Joined: Fri Aug 07, 2020 7:07 am

Re: Timezone Incorrect

Hello sachaMONDE!

Welcome to our forum and thanks for contacting us with your question!

It is hard to tell you what could be done here without taking look at your code. Could you reproduce the issue in an online editor that I could work on? You can find a basic template in the link below.

Demo: https://jsfiddle.net/BlackLabel/0pbeym97/

Best regards!
Dominik Chudy
Highcharts Developer

Return to “Highcharts Stock”