How can I get the previous high/low with MQL4 ?

 
for example as below screen capture:
Files:
question.jpg  211 kb
 
Topics concerning MT4 and MQL4 have their own section.
In future please post in the correct section.
I have moved your topic to the MQL4 and Metatrader 4 section.

 
Keith Watford:
Topics concerning MT4 and MQL4 have their own section.
In future please post in the correct section.
I have moved your topic to the MQL4 and Metatrader 4 section.

oh, thank you!

 
winsonet: for example as below screen capture:

From the image, it looks like you want the support zone. However, in coding, one must define things in very clear and precise manner and a support zone as you have shown is something "fuzzy" without a precise way to describe it mathematically or logically. It is a "human" thing.

So, if you want to calculate that zone, you have to start by first defining it in very precise manner. Break it down into logical steps. If it is too "fuzzy" to describe in a precise and logical manner, then create a simpler definition that is less "fuzzy" (less human), and make it more discreet (more computer like), for example looking for fractals instead of a zone.

As it is now, your image does not describe it sufficiently well, in order to offer you a code solution!