Discussion of article "How to Copy Trading from MetaTrader 5 to MetaTrader 4" - page 6

 

Very very useful work to use my MT5's EA with brokers that still use MT4 platform, thanks a lot !

Unfortunaltely I got some unexpected errors on MT4 side by using it (Terminal - Experts  windows) : "Copyist_positions EURUSD,M1: ArrayInitialize function internal error" 

And some  warnings when compiling source code on MT4 MetaEditor :" 'cmd' - comparison expression expected C:\Program Files\MetaTrader 5\MQL5\Files\MetaTrader 4\experts\Copyist_positions.mq4 (127, 46)"

Some idea to fix this bugs ? 


Documentation on MQL5: Array Functions / ArrayInitialize
  • www.mql5.com
Array Functions / ArrayInitialize - Documentation on MQL5
 
arnovinc:

Very very useful work to use my MT5's EA with brokers that still use MT4 platform, thanks a lot !

Unfortunaltely I got some unexpected errors on MT4 side by using it (Terminal - Experts  windows) : "Copyist_positions EURUSD,M1: ArrayInitialize function internal error" 

And some  warnings when compiling source code on MT4 MetaEditor :" 'cmd' - comparison expression expected C:\Program Files\MetaTrader 5\MQL5\Files\MetaTrader 4\experts\Copyist_positions.mq4 (127, 46)"

Some idea to fix this bugs ? 

Thank you, we will check it.

Try the codes from the original russian article.

 
Automated-Trading:

Thank you, we will check it.

Try the codes from the original russian article.

Bug is fixed now, I have just reinstalled MT5 & MT4 and it works !

Thanks a lot for your work. 

 
IvanIvanov:
Disconnected, restarted the computer, nothing...

...... I finally launched the copier on MT4, if necessary, I will tell you in detail how.
 

Cool thing ..... only one question.

I have an Expert Advisor and terminal under MT5 understand only lots of 0.1 volume, but I want to trade on MT4 on micro accounts with 0.01, that is, the Expert Advisor on MT5 opens 0.1 and in MT4 everything is divided by 10 and displayed accordingly 0.01 .....kovyryal code and did not understand where to put the division there.

 
snif_ram:

Cool thing ..... only one question.

I have an Expert Advisor and terminal under MT5 understand only lots of 0.1, but I want to trade on MT4 on micro accounts with 0.01, that is, the Expert Advisor on MT5 opens 0.1 and in MT4 everything is divided by 10 and displayed accordingly 0.01 .....kovyryal code and did not understand where to put the division there.

You don't need to dig anything in the code, for this purpose in the mt4 copier there is an extern variable koeff_lot, which is responsible for scaling.

If you change it to 0.1, then for every 1.0 lot in mt5, 0.1 lot will be opened in mt4.

Документация по MQL5: Основы языка / Переменные / Extern переменные
Документация по MQL5: Основы языка / Переменные / Extern переменные
  • www.mql5.com
Основы языка / Переменные / Extern переменные - Документация по MQL5
 
Urain:

And there is nothing in the code, for this purpose in the mt4 copier there is an extern variable koeff_lot, which is responsible for scaling.

If you change it to 0.1, then for every 1.0 lot in mt5 0.1 lot will be opened in mt4.

thank you very much ......
 
Hello ! Can you tell me what I'm doing wrong: I'm trying to install mt4 in C:\Program Files\MetaTrader 5\MQL5\Files\, but I can't find the Files folder. I open "open data catalogue" from the terminal. I see the Files folder there. I copied the already installed mt4 there, but the Expert Advisor in mt5 creates its own folder, which is not seen by the script in mt4. It says "file opening error 4103". If I copy the csv file to the mt4\experts\files folder, the script copies the deal. Shit, I'm ashamed of myself, but I can't figure out what's wrong.
Документация по MQL5: Файловые операции / FileCopy
Документация по MQL5: Файловые операции / FileCopy
  • www.mql5.com
Файловые операции / FileCopy - Документация по MQL5
 
Bank_616:
Hello ! Can you tell me what I'm doing wrong: I'm trying to install mt4 in C:\Program Files\MetaTrader 5\MQL5\Files\, but I can't find the Files folder. I open "Open Data Catalogue" from the terminal. I see the Files folder there. I copied the already installed mt4 there, but the Expert Advisor in mt5 creates its own folder, which is not seen by the script in mt4. It says "file opening error 4103". If I copy the csv file to the mt4\experts\files folder, the script copies the deal. Shit, I am ashamed of myself, but I can't figure out what is wrong.
In a similar situation I had to upload a new MT-4 terminal to the ...\ Files folder in MT-5 instead of the already installed one (WORKING-SCOOPED) after that the copying script worked.
 
osn:
In a similar situation I had to upload a new MT-4 terminal to the ...\ Files folder in MT-5 instead of the already installed one (WORKING-SCOOPPED), after that the copier script worked.

Thanks, I will try it.