Code for Broker Time Zone on Charts and for Local PC Time Zone

 
Is there a way to get the time zone offset from GMT of the broker's charts from a command that can be used in indicators and experts?

If not, could something to do this, be added to the next Build?

For example it would be great if a function or command such as MarketInfo(Symbol(),MODE_GMT); or something like that, was part of the MT4 coding language.

It would return an integer value of the offset in seconds (example: if broker is at GMT +1, the code would return 3600).

Calculating this offset from a known time can be done but it is not as good because charts can have time delays and down time, and the known time might not be synchronized or correct.

Also, is there a way to import the GMT offset of a local PC into the MT4 language, not by using TimeLocal() and comparing it to a known time but actually getting the offset value from the PC (e.g. -4 hours)?

If not, could this also be added to the next Build?

WRR
 
Yes; that would be nice; i want to double on this one....
 
See indicator Clock in Code Base - https://www.mql5.com/en/code/8075
 
Rosh,
thanks. I was able to extract the local time zone of my PC using the code you provided. However, there does not seem to be a way to get GMT offset of the broker by function. One can calculate it but it would be better if one had a function to retrieve it from the terminal since one can only calculate it during broker hours.

WRR
Reason: