Hi,
"Highest" will return the number of the higher bar, plus you were using (.... 1, 1) and that means the highest bar between bar 1 and 1, what you want to know is the highest bar 1 to 4, so you need to change the code to (... 4, 1).
Try this: BuyH = High[ Highest( NULL, PERIOD_H4, MODE_HIGH, 4, 1 ) ];
"Highest" will return the number of the higher bar, plus you were using (.... 1, 1) and that means the highest bar between bar 1 and 1, what you want to know is the highest bar 1 to 4, so you need to change the code to (... 4, 1).
Try this: BuyH = High[ Highest( NULL, PERIOD_H4, MODE_HIGH, 4, 1 ) ];
cleon:
Hi,
"Highest" will return the number of the higher bar, plus you were using (.... 1, 1) and that means the highest bar between bar 1 and 1, what you want to know is the highest bar 1 to 4, so you need to change the code to (... 4, 1).
Try this: BuyH = High[ Highest( NULL, PERIOD_H4, MODE_HIGH, 4, 1 ) ];
thanksHi,
"Highest" will return the number of the higher bar, plus you were using (.... 1, 1) and that means the highest bar between bar 1 and 1, what you want to know is the highest bar 1 to 4, so you need to change the code to (... 4, 1).
Try this: BuyH = High[ Highest( NULL, PERIOD_H4, MODE_HIGH, 4, 1 ) ];
it also return 1.
Hi,
Try to declare BuyH as a double. I'm pretty sure that BuyH = High[ Highest( NULL, PERIOD_H4, MODE_HIGH, 4, 1 ) ]; doesn't return 1, the problem must be somewhere else.
Try to declare BuyH as a double. I'm pretty sure that BuyH = High[ Highest( NULL, PERIOD_H4, MODE_HIGH, 4, 1 ) ]; doesn't return 1, the problem must be somewhere else.

You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
i use the higest function in my codes:"BuyH=Highest(NULL,PERIOD_H4,MODE_HIGH, 1,1);"
but it always return BuyH is 1?
May someone can help me? thanks.