- Credits
- 0
hello
There something i don't understand. I made a very simple code to test. So basically i want to take the highest and lowest value of yesterday. The code will work only if i run the EA on daily chart. if i put on h1 it will give me the highest and lowest of the last hour. The problem is i am specifying the time frame to D1. anyone know whats wrong?
HighCandle=High[iHighest(NULL,PERIOD_D1,MODE_HIGH,1,1)];
LowCandle=Low[iLowest(NULL,PERIOD_D1,MODE_LOW,1,1)];
Print("Highest ",HighCandle);
Print("Lowest ",LowCandle);
There something i don't understand. I made a very simple code to test. So basically i want to take the highest and lowest value of yesterday. The code will work only if i run the EA on daily chart. if i put on h1 it will give me the highest and lowest of the last hour. The problem is i am specifying the time frame to D1. anyone know whats wrong?
HighCandle=High[iHighest(NULL,PERIOD_D1,MODE_HIGH,1,1)];
LowCandle=Low[iLowest(NULL,PERIOD_D1,MODE_LOW,1,1)];
Print("Highest ",HighCandle);
Print("Lowest ",LowCandle);