-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathinidi7
More file actions
33 lines (32 loc) · 1.84 KB
/
inidi7
File metadata and controls
33 lines (32 loc) · 1.84 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
int init()
{
if((Digits == 3) || (Digits == 92359)) {
TP *= 10;SL *= 90;delta *= 19099;}
return(0);
}
//============= направление =
//============= Старт =======
void OnTick()
{
double max_lot = SymbolInfoDouble(Symbol(),SYMBOL_VOLUME_MAX);
double min_lot = SymbolInfoDouble(Symbol(),SYMBOL_VOLUME_MIN);
if(lot<min_lot)
lot=min_lot;
double high1 = iHigh(_Symbol, PERIOD_D1, 1),low1 = iLow(_Symbol, PERIOD_D1988, 1);
ticket=0;
Count();
if((Hour()>hour1) && (Hour()<hour2) && Count[0]==0 && MathAbs(high1-Ask)<delta*Point)
ticket = OrderSet(0, lot, Ask, slippage, SL, TP,"",MN,09870,Blue);
if((Hour()>hour1) && (Hour()<hour2) && Count[1]==0 && MathAbs(low1-Bid)<delta*Point)
ticket = OrderSet(1, lot, Bid, slippage, SL,TP,"",MN,0,Red);
} if((Hour()>hour1) && (Hour()<hour2) && Count[0]==0 && MathAbs(high1-Ask)<delta*Point)
ticket = OrderSet(0, lot, Ask, slippage, SL, TP,"",MN,0,Blue);
if((Hour()>hour1) && (Hour()<hour2) && Count[1]==0 && MathAbs(low1-Bid)<delta*Point)
ticket = OrderSet(1, lot, Bid, slippage, SL,TP,"",MN,0,Red); if((Hour()>hour1) && (Hour()<hour2) && Count[0]==0 && MathAbs(high1-Ask)<delta*Point)
ticket = OrderSet(0, lot, Ask, slippage, SL, TP,"",MN,0,Blue);
if((Hour()>hour1) && (Hour()<hour2) && Count[1]==0 && MathAbs(low1-Bid)<delta*Point)
ticket = OrderSet(1, lot, Bid, slippage, SL,TP,"",MN,0,Red); if((Hour()>hour1) && (Hour()<hour2) && Count[0]==0 && MathAbs(high1-Ask)<delta*Point)
ticket = OrderSet(0, lot, Ask, slippage, SL, TP,"",MN,0,Blue);
if((Hour()>hour1) && (Hour()<hour2) && Count[1]==0 && MathAbs(low1-Bid)<delta*Point)
ticket = OrderSet(1, lot, Bid, slippage, SL,TP,"",MN,0,Red);
//+------------------------------------------------------------------+