> compliation error...
And the error message is...?
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
Hi
I have the code below ... the line in red keeps giving a compliation error - I cannot for the life of me see what is wrong - can anybody spot it? (BarIndex is a function defined and coded at the bottom of the script)
Thanks
Paul
#define TF 9
#define MAX 999
#define SRT 3
#define VAL 0
#define TIME 1
#define BEG 2
#define SEND 3
#define REND 4
#define SCNT 5
#define RCNT 6
#define TFR 7
extern int FractalBars = 9;
extern int Battered = 1;
extern int Breached = 3;
extern int BBLimit = 3;
int SRTimeFrames[SRT] = {PERIOD_D1,PERIOD_H4,PERIOD_H1};
int TimeFrames[TF] = { PERIOD_MN1,
PERIOD_W1,
PERIOD_D1,
PERIOD_H4,
PERIOD_H1,
PERIOD_M30,
PERIOD_M15,
PERIOD_M5,
PERIOD_M1};
bool NewBars[TF] = {false,false,false,false,false,false,false,false,false};
datetime BarTimes[TF] = {0,0,0,0,0,0,0,0,0};
int NoFractals=0;
double Fractals[1][8];
bool NewPeriodBar;
datetime PeriodBarTime;
///////////
// function
///////////
int init () {
for (int i=0;i<SRT;i++) {
for (int m=MAX-FractalBars;m>=FractalBars+1;m--) {
CheckNewFractal(SRTimeFrames[i],m);
}
}
DrawAllFractals(true);
return (0);
}
///////////
// function
///////////
int deinit () {
ObjectsDeleteAll(EMPTY,OBJ_TREND);
return (0);
}
///////////
// function
///////////
int start () {
CalcNewBars();
for (int i=0;i<SRT;i++) {
if (NewBars[BarIndex(SRTimeFrames[i])] == true) {
UpdateFractals(SRTimeFrames[i]);
CheckNewFractal(SRTimeFrames[i],1+FractalBars);
}
}
if (NewPeriodBar == true) DrawAllFractals(false);
return (0);
}