I’m building a basic EA. I would like to enter a long position on the high of the last x hourly candle.
Is the timeframe of the chart overruling the timeframe set on the EA? If in the code I calculate the high on the hourly candle (double HighEntry = High[iHighest(“EURUSD”,60,MODE_HIGH,48,1)]), but then I change the chart from hourly to any other timeframe, then the high is not calculated anymore on the hourly candles but on the timeframe that I selected for the chart.
I thought that by specifying the timeframe in the code, the EA would have calculated the high on the coded timeframe, even if the chart (in which the EA is running) is running on a different timeframe.
Thanks