MT5 lags or frezze when using EA and indicator on same chart (no problem with MT4)

 

Hi,

I have situation when I load EA and Indicator on same chart and if I start clicking EA action buttons very quickly then EA freeze.

If I have only EA on chart then everything works perfect. I can click buttons very quickly. If I load only indicator on chart then I can also clicking on indicator action buttons very quickly.

When doing same fast clicking on buttons on MT4 with same EA and indicator on one chart, then there is no problem with freeze or lag.

 

Do you have any tips what can be causing this strange behavior in MT5?

Did I missed some programming concepts that are diferent in MT5?

 
Igor Zizek: I have situation when I load EA and Indicator on same chart and if I start clicking EA action buttons very quickly then EA freeze. If I have only EA on chart then everything works perfect. I can click buttons very quickly. If I load only indicator on chart then I can also clicking on indicator action buttons very quickly. When doing same fast clicking on buttons on MT4 with same EA and indicator on one chart, then there is no problem with freeze or lag. Do you have any tips what can be causing this strange behavior in MT5? Did I missed some programming concepts that are diferent in MT5?

MetaTrader/MQL v5 can be quite different to v4 in certain areas and the same in others. There is something wrong with your code, and you will need to fix it so as not to cause that problem on MT5.

 
Igor Zizek:

Hi,

I have situation when I load EA and Indicator on same chart and if I start clicking EA action buttons very quickly then EA freeze.

If I have only EA on chart then everything works perfect. I can click buttons very quickly. If I load only indicator on chart then I can also clicking on indicator action buttons very quickly.

When doing same fast clicking on buttons on MT4 with same EA and indicator on one chart, then there is no problem with freeze or lag.

 

Do you have any tips what can be causing this strange behavior in MT5?

Did I missed some programming concepts that are diferent in MT5?

Are you using ObjectsDeleteAll() ?

 
Alain Verleyen:

Are you using ObjectsDeleteAll() ?

I am not using ObjectsDeleteAll() in my code

 

Do you think that there is maybe some problem if EA and indicator have timer on one chart?

Or maybe some problem with events betwen EA and indicator?

 
Igor Zizek:

Do you think that there is maybe some problem if EA and indicator have timer on one chart?

Or maybe some problem with events betwen EA and indicator?

All is possible. Without code nobody can help you further.

Reason: