
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 tried to figure out the parameters the iCustom but i didn't achieved to find out how to receive the 5 day high and 5 day low price so to make my calculations when price break the up or down level.
Out of the OnTick() i add this code which i copy paste from indicator's code source:
// input parameters for 5-day-breakout indicator
//---- input parameters
extern int DAYS=5;
//---- Variables
double yesterday_close,Current_price;
double phigh,plow,plownew;
int i=1;
//---- Buffers
double daily_high[20] ;
double daily_low[20] ;
From source code but also from data window we understand that we have two buffers but my main problem is, if i set the right parameters insite the iCustom()
Inside the OnTick() i add this code:
double breakout_high= iCustom(_Symbol,_Period,"5DayBreakOut",DAYS,0,0);
double breakout_low= iCustom(_Symbol,_Period,"5-day-breakout",DAYS,1,0);
double breakout_box= daily_high[20]-daily_low[20];
I also tried :
double breakout_box = phigh-plow;
double breakout_box= breakout_high-breakout_low;
About iCustom() i tried also after DAYS parameter to add the variable names separating by comma.
The one file is in mq4 which you can see the source code but i observed when i attach it on chart, i must allow DLL imports so the 5high and 5 low price to be appeared.
In opposition the second file is in ex4 which you can not see the source code( and i guess must be almost the same) but the price appear on chart without
to tick the "Allow DLL imports".