Download MetaTrader 5
To add comments, please log in or register
1000 developers are involved in Freelance service activity. Sign up!
FaatP94
64
FaatP94 2014.10.08 23:45 
Hello, how can I get the highest and lowest price for the last 50 bars ? I'm new at mql and have no idea. 
honest_knave
Moderator
1919
honest_knave 2014.10.08 23:54  

iHighest will tell you which bar made the highest price over the period specified (you want the last 50 bars). The bar number is called a shift.

iLowest will tell you which bar made the lowest price. 

You can then retrieve the actual price using High (or Low).

So if iHighest told you the highest price was on bar 39, you would retrieve that price with High[39].

Links should explain along with examples.

FaatP94
64
FaatP94 2014.10.09 00:43  
Thank you very much I will try it now 
/
To add comments, please log in or register