Any questions from newcomers on MQL4 and MQL5, help and discussion on algorithms and codes - page 494

 
lil_lil:

Thank you, just what I needed.

Might be useful to know, there is an error in missing positions--- ToFile EURUSD,H1: zero divide in 'ToFile.mq4' (62,39)

The text does not change in the tester, there is no such option?

Thank you. That was the reason for installing the button. Instead of this line it must be: or check at the beginning and return;

   Строка= AccountMargin()==0 ? " - ":
        DoubleToStr(AccountEquity()/AccountMargin()*100,2)+"%"; // Уровень=Средства/Залог

Which text are we talking about?

 
STARIJ:

Which text are we talking about?

The text of the button does not change when pressed in the strategy tester. Do you need to add something?

 
lil_lil: The text of the button does not change when pressed in the strategy tester. Is there anything you need to add?

Maybe you have some kind of error. Perhaps, the tester has restrictions on working with graphical objects. As a last resort, try if(isTesting) try to delete the button and recreate it

 
STARIJ:

Maybe you have some kind of error. Perhaps the tester has restrictions on working with graphical objects. As a last resort, try if(isTesting) try deleting the button and creating it again

And the continuation of the universal recommendation

Forum on trading, automated trading systems and strategy tester

Tester: TakeProfit = negative value

STARIJ, 2018.03.21 05:43

Once there was a rare case - computer gave 0 when performing addition of two certain numbers. On other numbers everything was fine. That's how the processor had to be replaced. Sometimes restarting the computer helps to eliminate the errors. If on all EAs - reinstall the terminal. After installation, make a copy of the terminal folder immediately - use it in the future instead of reinstalling. If one Expert Advisor is like this - contact ServiceDesk through your profile


 
lil_lil:

The text of the button does not change when pressed in the strategy tester. Is there anything to add?

In the tester OnChartEvent() does not work.
 
lil_lil:

There is a "Stop" button, how do I change its text to "Start" once pressed?

      if(ObjectGetInteger(0,"Stop",OBJPROP_STATE,false))
       ObjectSetString(0,"Stop",OBJPROP_TEXT,"Stop");
      if(ObjectGetInteger(0,"Stop",OBJPROP_STATE,true))
       ObjectSetString(0,"Stop",OBJPROP_TEXT,"Start");
 
Hi all, advise a beginner, in the EA I select a stop to take 1k3, 30 and 90 p, respectively, but why in the strategy tester mt4 in the tab results take is always gets 1k 2.7 somewhere?
 
Alexey Viktorov: And a continuation of the universal recommendation

Thank you for reminding me...

 
Вадим Мотеюнас:
Hi all, advise a beginner, in the EA I select a stop to take 1k3, 30 and 90 p, respectively, but why in the strategy tester in the MT4 tab results take is always obtained 1k 2.7 somewhere?

swap

 

This MT4 tester is bugging me!!! Loss trades 0, total loss 0, but the drawdown is huge!!!

Reason: