Errors, bugs, questions - page 1608

 

what's the trick with me not finding a definition for POSITION_COMMISSION not even highlighted in blue? (5.00 1340)

 
Karputov Vladimir:

What is the build of the terminal? If you connect to another trade server in the same terminal (did you know that you can connect to any trade server from one terminal?) - how will the EAs behave?

Insert a screenshot of the strategy tester, tab "Settings" here. Let's see what settings are there.

I connected from a terminal from another company in which I have all my EAs working. I did not have any trades after I entered bx credentials and started any Expert Advisor in the strategy tester. Bx's build is 1340

 
Danil Nesterov:

I connected from a terminal from another company in which I have all EAs working. After entering the credentials from bx and running any advisor in the strategy tester trades are no longer executed. Bx build 1340

Check permissions to trade:

//+------------------------------------------------------------------+
//|                                                      IsTrade.mq5 |
//|                              Copyright © 2015, Vladimir Karputov |
//|                                           http://wmua.ru/slesar/ |
//+------------------------------------------------------------------+
#property copyright "Copyright © 2015, Vladimir Karputov"
#property link      "http://wmua.ru/slesar/"
#property version   "1.00"
//+------------------------------------------------------------------+
//| Script program start function                                    |
//+------------------------------------------------------------------+
void OnStart()
  {
//---
   if(!TerminalInfoInteger(TERMINAL_TRADE_ALLOWED))
      Alert("Проверьте в настройках терминала разрешение на автоматическую торговлю!");
   else
     {
      if(!MQLInfoInteger(MQL_TRADE_ALLOWED))
         Alert("Автоматическая торговля запрещена в свойствах программы для ",__FILE__);
     }

   if(!AccountInfoInteger(ACCOUNT_TRADE_EXPERT))
      Alert("Автоматическая торговля запрещена для счета ",AccountInfoInteger(ACCOUNT_LOGIN),
            " на стороне торгового сервера");

   if(!AccountInfoInteger(ACCOUNT_TRADE_ALLOWED))
      Comment("Торговля запрещена для счета ",AccountInfoInteger(ACCOUNT_LOGIN),
              ".\n Возможно, подключение к торговому счету произведено по инвест паролю.",
              "\n Проверьте журнал терминала, есть ли там такая запись:",
              "\n\'",AccountInfoInteger(ACCOUNT_LOGIN),"\': trading has been disabled - investor mode.");

  }
//+------------------------------------------------------------------+
Files:
IsTrade.mq5  2 kb
 
Karputov Vladimir:

Check the permissions for the trade:

Started the script. There were no alerts.

 
Danil Nesterov:

I ran the script. There were no alerts.

Have you tried putting USD instead of roubles in the tester?
 
Karputov Vladimir:
Have you tried putting USD instead of roubles in the tester?
No, I haven't. Not quite sure how to do it. Can you tell me?
 

The first time you run a test, the Expert Advisor loads the *.ex5 library into memory, and then it uses the library loaded into memory, and if the library has changed, the Expert Advisor uses the old one, the one that is in memory.

I think the tester should check if the library has changed...

 
Vladimir Pastushak:

I'm confused, I want to clarify Timeframes(OBJ_NO_PERIODS) can change the order in which objects are drawn ?

In my case, the order of picture A picture B picture C

By usingOBJ_ALL_PERIODS can the order be changed to any other ? B C A ????

When an object is rendered invisible for all timeframes (at least for the timeframe that is currently in the chart), the object is removed from the rendering list.

When object visibility is restored for the working timeframe (in our case for all timeframes), the object is added to the end of the drawing list.

To change the drawing order for three objects, first disable visibility for all three objects (no matter what order). Then turn on visibility for the objects in the order you want - the first object will be at the bottom, the second object in the middle, and the third object at the top.

 
Andrey Dik:

The first time you run a test, the Expert Advisor loads the *.ex5 library into memory, and then it uses the library loaded into memory, and if the library has changed, the Expert Advisor uses the old one, the one that is in memory.

I think the tester should check if the library has changed...

This check is performed. And if it turns out that one of the components has changed, it resends this component to the tester.
 
Karputov Vladimir:
Have you tried putting USD instead of roubles in the tester?
It won't work in the five.
Reason: