Data exchange between two EA's
In the window EURUSD is a program EA-1. And in the window GBPJPY is a program EA-2. How can data be handed over from EA-1 to EA-2?
- how to exchange variables between MT4's Indicators and EAs?
- a question about parameter passing
- Expert program does not start
if what you need is to exchange data of double, bool, or int type, then you can do:
//"ea-1.mq4"
start()
{
..
..
GlobalVariableSet("level_eurusd", Ask);
}
//"ea-2.mq4"
start()
{
..
..
double eurusd_level = GlobalVariableGet("level_eurusd");
}
If you need to exchange strings, then either use file operations, or a more complex but flexyble solution a DLL.