EA that can open an order on a different chart with different timeframes

 
Hi,

I would like to ask if is it possible to create an EA where if it makes an initial trade at higher timeframe (i.e., 4H), it will automatically open another chart (same symbol) but with different timeframe (i.e., 5M) and perform another trade automatically until SL or TP is hit?
 
Yvan Tarong:
Hi,

I would like to ask if is it possible to create an EA where if it makes an initial trade at higher timeframe (i.e., 4H), it will automatically open another chart (same symbol) but with different timeframe (i.e., 5M) and perform another trade automatically until SL or TP is hit?

You don't need that as you can get all the values of different timeframes by integrated functions, see: https://www.mql5.com/en/docs/function_indices.

E.g. CopyBuffer() for indicators and CopyRates() for the quotes.

Documentation on MQL5: List of MQL5 Functions
Documentation on MQL5: List of MQL5 Functions
  • www.mql5.com
All MQL5 functions in alphabetical order...
 
Carl Schreiber #:

You don't need that as you can get all the values of different timeframes by integrated functions, see: https://www.mql5.com/en/docs/function_indices.

E.g. CopyBuffer() for indicators and CopyRates() for the quotes.

Thank you for the response. I will check the articles.

 
Yvan Tarong: I would like to ask if is it possible to create an EA where if it makes an initial trade at higher timeframe (i.e., 4H), it will automatically open another chart (same symbol) but with different timeframe (i.e., 5M) and perform another trade automatically until SL or TP is hit?

Not possible with US brokers, due to FIFO rules.