Convertime

Moderator: admin

Convertime

Postby LeTigre30 » Fri May 13, 2016 5:41 am

Hello to whom it concerned,

I need to know the local date of a period (my time zone)
I use the following code :

TimeEST = core.host:execute("convertTime", "core.TZ_EST", "core.TZ_LOCAL", source:date(period));
TimeLOCAL = core.dateToTable(TimeEST);

But it doen't correct as the returned date is over 6 hours in the future :

What I need :

EST time = 05:30 ; Local Time = 11:30

Can someone helps me for the good coding ?

Best Regards
User avatar
LeTigre30
FXCodeBase: Initiate
 
Posts: 173
Joined: Sun Dec 19, 2010 5:10 am
Location: Nimes (France)

Re: Convertime

Postby Apprentice » Tue May 17, 2016 5:09 am

TimeLocal = core.host:execute("convertTime", "core.TZ_EST", "core.TZ_LOCAL", source:date(period));
User avatar
Apprentice
FXCodeBase: Confirmed User
 
Posts: 36341
Joined: Thu Dec 31, 2009 11:59 am
Location: Zagreb, Croatia


Return to Indicator Development

Who is online

Users browsing this forum: No registered users and 12 guests