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

[Deleted]  
joo:
Yeah, I did it on Win7. No problems. UAC disabled.

Yay,

I'm fine with the translator, but the copier won't start....

Do you put the copier in the scripts? Default settings or do you need to switch something off? What is UAC disabled?

I apologise if the questions are amateurish, I'm new to mt....

[Deleted]  
IvanIvanov:
What is UAC disabled?

User Account Control
[Deleted]  
Unplugged it, rebooted the comp, nothing.....
 
IvanIvanov:
Unplugged it, rebooted the computer, nothing....

"When nothing works, read the manual." :)

Maybe you should reread the article? If it doesn't help again, please describe your actions in detail, maybe then you will be able to eliminate (I think it sounds better than - "solve" :) ) the problem.

 
joo:

"When nothing works, read the manual". :)

Maybe you should reread the article? If it doesn't help again, then describe your actions in detail, perhaps then you will be able to eliminate (I think it sounds better than "solve" :) ) the problem.

I agree with Mr Ivanov, I have a completely similar situation. In MT4 the script seems to be attached to the chart, but there is no comment and the log says " file opening error 4103" and "Array initialise function internal error". I am also an amateur in programming and this is my first time on the forum, so I will be grateful for any help .......
Документация по MQL5: Файловые операции / FileOpen
Документация по MQL5: Файловые операции / FileOpen
  • www.mql5.com
Файловые операции / FileOpen - Документация по MQL5
 
IvanIvanov:
the copier will not start....

Check whether"Allow EA to trade" is ticked in MT4.
 

Nicholas, once again I would like to thank you for a wonderful instrument. One more thought on modernisation.

Sometimes it happens that in MT4 a position closes, then at the same moment it opens again and closes immediately. I could not understand what is the matter. And here is the point, look:

1. opened a position in MT5 with TR and SL.

2. opened a position in MT4 with TR and SL.

3. Due to the difference in quotes, TR or SL was triggered in MT4, but not yet in MT5.

4. the copier reopens the position (because in MT5 it has not been closed yet).

5. TR or SL is triggered in MT5

6. the position is closed in MT4

You get an extra trade in MT4.

The solution is very simple - in fact, there is no need to transmit TR and SL in MT4, it is redundant information, because the position will be closed there anyway after closing in MT5.

And the code will be smaller and the numbers on the chart will be less jittery in your eyes:)

 
SoundChip:

Nicholas, once again I would like to thank you for a wonderful instrument. One more thought on modernisation.

Sometimes it happens that in MT4 a position closes, then at the same moment it opens again and closes immediately. I could not understand what is the matter. And here is the point, look:

1. opened a position in MT5 with TR and SL.

2. opened a position in MT4 with TR and SL.

3. Due to the difference in quotes, TR or SL was triggered in MT4, but not yet in MT5.

4. the copier reopens the position (because in MT5 it has not been closed yet).

5. TR or SL is triggered in MT5

6. the position is closed in MT4

You get an extra trade in MT4.

The solution is very simple - in fact, there is no need to transmit TR and SL in MT4, it is redundant information, because the position will be closed there anyway after closing in MT5.

And the code will be smaller and the numbers on the chart will be less jittery in your eyes:)


When developing the copier, I have specially allocated the setting of stop levels in a separate block. Thanks to this, it can be easily disabled by adding an external state flag and control this flag via a global variable. That's why the code is flexible for modifications.

You can also automate the process by setting stop levels when exiting the script and on the last bar of the session. Then your trade will be protected from market surprises when you lose control.

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

You can also automate the process by setting stop levels when exiting the script and on the last bar of the session. Then your trade will be protected from market surprises in moments of loss of control.

Yes, stops would probably be useful here. But I decided to remove them from the code and simplify them to the maximum. Let's see what happens:)
 
Useful, If it works for me at demo I am going to try this on real account.
Documentation on MQL5: Standard Constants, Enumerations and Structures / Environment State / Account Properties
  • www.mql5.com
Standard Constants, Enumerations and Structures / Environment State / Account Properties - Documentation on MQL5