[Q] Get data from different charts on a single EA?

 

Is it possible to get data from different charts on a single EA?

I am not talking about MTF, but instead getting object names and descriptions, for example, from different charts.

Example: if chart 1 has object X and chart 2 has object Y then EA that is active on chart 3 will open trade.

 

I've tried googling and searching these forums, but couldn't find anything. If there is something, maybe I searched with the wrong keywords.

 

Thank you 

 

Off the top of my head, I think you could use file to communicate between the charts. Given your example, have Expert/Indicator/Script on Chart 1 & 2 write to file. Let them say what they have and Chart 3 could read that file and respond accordingly.

There may or may-not be issues with 3-.ex4 trying to access a particular file at the same time [i cannot remember]. Someone else might know and answer soon, other-wise you could test-it or use a Mutex [wait for access if in use].

 
raidenfx:

Is it possible to get data from different charts on a single EA?

I am not talking about MTF, but instead getting object names and descriptions, for example, from different charts.

Example: if chart 1 has object X and chart 2 has object Y then EA that is active on chart 3 will open trade.

Objects are local to the chart, so you can't directly.

You can have one EA create Global Variable(s) about what's on it's chart and the other EA read them.

 

Thank you guys!

 I think I'll give a try to WHRoeder solution, seems more pratical.