Meta Trader 4 No Connection

 

Hello. When I open MT4 with my default profile (about 10 charts with custom indicators) it does not connect. Sometimes it shows servers and pings, but still no connection.

The only way it works is that I go to another profile with 1 chart, no custom indicator, and restart MT4, then it connects.

Where is the problem? How opened charts and custom indicators can cause no connection problem?!

 
  • If it is real/live trading account so ask your broker for support.
  • If it is demo account so create the other demo account with any broker (it is less than 1 minutes to do directly from Metatrader) and continue trading (because many brokers are disabling the demo account so we need to create the new one or the other one).
 
Sergey Golubev #:
  • If it is real/live trading account so ask your broker for support.
  • If it is demo account so create the other demo account with any broker (it is less than 1 minutes to do directly from Metatrader) and continue trading (because many brokers are disabling the demo account so we need to create the new one or the other one).

It's real account. The broker does not have any answer for this problem!

 
Farzad Sadeghishahrestanak #:

It's real account. The broker does not have any answer for this problem!

It is broker's related issue anyway sorry.
 
Sergey Golubev #:
It is broker's related issue anyway sorry.

No it was not from broker side. I found the problem and fixed it. A function which draw spread lines should only run when i=0 but wrongly was located in main loop of the custom indicator. I do not know how it causes connection problem, but I tested it in 2 different brokers' MT. both could not connect, but after fixing the code both connected.

 
Farzad Sadeghishahrestanak #: I do not know how it causes connection problem,

While an indicator is running, nothing else can happen. That includes connecting. Indicators must return; they can not delay the terminal.

 
I'm glad you posted this and the fact you sorted it.  I've got exactly this problem and now know where to look for a solution.