Synchronize computer time

 

hi everyone

is there any way to Synchronize the computer time with the servers time?

thanks

 
There's a time indicator provided in the code base which should provide you with the broker server-time. For windows time synchronization/settings try searching google.
 
ubzen:
There's a time indicator provided in the code base which should provide you with the broker server-time. For windows time synchronization/settings try searching google.

i was wondering, did u answered my question ?
 

Lol... You mean short of me searching google and the forum for a One-Hit-Buttons or Win32.dll or Api's which says Synchronize my local computer time with my broker's server time? No, you'll have to search for that yourself.

 

What I did answer is that you can adjust your computer time to the broker's server time. You get the broker's server time by calling them, or using tools that tell you the broker's time.

 
ubzen:

What I did answer is that you can adjust your computer time to the broker's server time. You get the broker's server time by calling them, or using tools that tell you the broker's time.


opss ammmmmmm i didn't know this LOL
 

ubzen:

You get the broker's server time by calling them, or using tools that tell you the broker's time.

You get the broker's server time by simply looking at the chart. No need for a phone call.
 

i whan Synchronize computer time with the server time with an EA

 

should be enough to set your clock to the correct time zone. Windows can synchronize its clock automatically from some public time servers on the internet (I think this is even on by default already). Once you have to set the correct time zone in the control panel it should just work.

 
//+------------------------------------------------------------------+
//|                                        SyncCompClockToServer.mq4 |
//|                                         Copyright © 2010, nadav. |
//+------------------------------------------------------------------+
#property copyright "Copyright © 2010, NADAV."
//+------------------------------------------------------------------+
//| script program start function                                    |
//+------------------------------------------------------------------+
#import "shell32.dll" 
int ShellExecuteA(int hwnd,string Operation,string File,string Parameters,string Directory,int ShowCmd); 
int start()
  {
//----
   string ServerTime = TimeToStr(TimeCurrent(),TIME_SECONDS);
   string ServerDate = TimeToStr(TimeCurrent(),TIME_DATE);
   string mm = StringSubstr(ServerDate,5,2);
   string dd = StringSubstr(ServerDate,8,2);
   string yy = StringSubstr(ServerDate,2,2);
   ShellExecuteA(0, "Open", "cmd.exe", "/c date" + " " + mm + "-" + dd + "-" + yy, "", 1); 
   ShellExecuteA(0, "Open", "cmd.exe", "/c time" + " " + ServerTime, "", 1); 
//----
   return(0);
  }
//+------------------------------------------------------------------+
Reason: