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
а на демо счете вооще ни как себя не проявляет во вложенгии посмотрите. зарание благодарен с уважением Егор! lenok_lenin@inbox.ru
how can I contact you
I don't write to order
народ помогите не могу найти ни одного нормального советника перепробовал очень много! все показывают убыток как я не подгонял их тестере! если есть нормальный скинте эл я написал. зарание благодарен
Help to get the EA up and running. Reduced to minimum. Cycles incorrectly and gives error 130.
extern int period_EMA = 233,
period_SMA = 233,
stoploss = 200,
Magic = 55;
extern double Lot = 0.01;
extern string TimeEnd = "22:00"; //boundary time for Hai or Low
extern string TimeSetOrders = "00:30"; // order placing time.
extern string TimeDelOrders = "13:00"; // Time of deleting orders
extern int LevelWLoss = 1; // Breakeven level
extern inttern LevelProfit = 40; // Profit Level
extern bool AllSymbols = True; // Watch positions of all symbols
extern int Ticket = -1; // Position identifier (corrected!!!)
extern bool TSProfitOnly = True; // Trawl profit only
extern intStop.Buy = 1000; // Trawl size in points for buying
extern int TStop.Sell = 1000; // Trawl size in points for selling
extern int TrailingStep = 100; // Trailing step in points
int HiTime,LoTime;
int time; // on the next bar roll values
int currDay,i=0;
void start() {
if (TimeToStr(CurTime(), TIME_MINUTES)==TimeSetOrders) SetLimOrd(); // Time =00.30, then place orders
if (TimeToStr(CurTime(), TIME_MINUTES)==TimeDelOrders) DelLim(); // Time ==13.00, delete the pending orders
return (0);
}
//+------------------------------------------------------------------+
//| deletion of limiters not triggered |
//+------------------------------------------------------------------+
void DelLim()
{
for (int i=0;i<OrdersTotal();i++)
{
if (OrderSelect(i,SELECT_BY_POS)&&OrderSymbol()==Symbol()&&OrderType()==2||3)
OrderDelete(OrderTicket());
}
return (0);
}
//+------------------------------------------------------------------+
//| Setting pending orders |
//+------------------------------------------------------------------+
void SetLimOrd() {
//------- Daily prices, Fibs and Hi-Low draw time--------------+
int shift = iBarShift(NULL,1440,Time[0]) + 1;
double HiPrice = iHigh(NULL,1440,shift); //High price
double LoPrice = iLow(NULL,1440,shift); // low price
double OpPrice = iOpen (NULL,1440,shift); //open price
double ClPrice = iClose (NULL,1440,shift); // Closing price
datetime StTime = iTime(NULL,1440,shift);
double Pivot =(HiPrice+LoPrice+ClPrice)/3;
double Range =HiPrice-LoPrice;
double Fibo138 =1.382*Range;
double Fibo162 =1.618*Range;
double Fibo262 =2.618*Range;
double Fibo_138 =(LoPrice-1.382*Range)-Range;
double Fibo_162 =(LoPrice-1.618*Range)-Range;
double Fibo_262 =(LoPrice-1.218*Range)-Range;
// ??
if(TimeDayOfWeek(StTime)==0/*Sunday*/){ //Add fridays high and low
HiPrice = MathMax(HiPrice,iHigh(NULL,1440,shift+1));
LoPrice = MathMin(LoPrice,iLow(NULL,1440,shift+1));
OpPrice = iOpen(NULL,1440,shift+1);
ClPrice = iClose(NULL,1440,shift+1);
Pivot =(HiPrice+LoPrice+ClPrice)/3;
Range =HiPrice-LoPrice;
Fibo138 =1.382*Range;
Fibo162 =1.618*Range;
Fibo262 =2.618*Range;
Fibo_138 =(LoPrice-1.382*Range)-Range;
Fibo_162 =(LoPrice-1.618*Range)-Range;
Fibo_262 =(LoPrice-1.218*Range)-Range;
}
//---------------- time hai and low-----------------------------------------+
if (time!=Time[0]){HiTime=0;LoTime=0;time=Time[0];}
if (High[0]>HiPrice)HiTime=TimeCurrent();
if (Low[0]<LoPrice)LoTime=TimeCurrent();
Comment("On this bar: "+"\n Time High Point="+HiTime+"\n Time Low Point="+LoTime);
//-----------------Ценовой диапазон Демарка-------------------------------+
if (currDay!=TimeDay(Time[i])){
if (ClPrice<OpPrice) double x=(HiPrice + LoPrice + ClPrice + LoPrice)/2;
if (ClPrice>OpPrice) x=(HiPrice + LoPrice + ClPrice + HiPrice)/2;
if (ClPrice==OpPrice) x=(HiPrice + LoPrice + ClPrice + ClPrice)/2;
i++;
}
double MaxDay = x - LoPrice;
double MinDay = x - HiPrice;
//----------Скользящие средние---------------------------------------------+
double EMA = iMA(15,0,period_EMA,0,MODE_EMA, PRICE_CLOSE,0)
double SMA = iMA(15,0,period_SMA,0,MODE_SMA,PRICE_CLOSE,0);
double EMA1 = iMA(60,0,period_EMA,0,MODE_EMA,PRICE_CLOSE,0);
double SMA1 = iMA(60,0,period_SMA,0,MODE_SMA,PRICE_CLOSE,0);
//----------Ордера---------------------------------------------------------+
HiPrice=NormalizeDouble(HiPrice,Digits);
LoPrice=NormalizeDouble(LoPrice,Digits);
Pivot=NormalizeDouble(Pivot,Digits);
Fibo138=NormalizeDouble(Fibo138,Digits);
Fibo162=NormalizeDouble(Fibo162,Digits);
Fibo_138=NormalizeDouble(Fibo_138,Digits);
Fibo_162=NormalizeDouble(Fibo_162,Digits);
double poi=MarketInfo(OrderSymbol(),MODE_POINT);
if (HiTime>LoTime){
int ticket1 =OrderSend(Symbol(),OP_SELLLIMIT,Lot,HiPrice,0,HiPrice+stoploss*poi,Pivot,NULL,Magic,0,Red);
int ticket2 =OrderSend(Symbol(),OP_SELLLIMIT,Lot,Fibo138,0,Fibo138+stoploss*poi,HiPrice,NULL,Magic,0,Red);
int ticket3 =OrderSend(Symbol(),OP_SELLLIMIT,Lot,Fibo162,0,Fibo162+stoploss*poi,HiPrice,NULL,Magic,0,Red);
}
if (HiTime<LoTime){
int ticket4=OrderSend(Symbol(),OP_BUYLIMIT,Lot,LoPrice,0,LoPrice-stoploss*poi,Pivot,NULL,Magic,0,Red);
int ticket5=OrderSend(Symbol(),OP_BUYLIMIT,Lot,Fibo_138,0,Fibo_138-stoploss*poi,LoPrice,NULL,Magic,0,Red);
int ticket6=OrderSend(Symbol(),OP_BUYLIMIT,Lot,Fibo_162,0,Fibo_162-stoploss*poi,LoPrice,NULL,Magic,0,Red);
}
if (HiTime>LoTime && ClPrice>Pivot) {
int ticket7=OrderSend(Symbol(),OP_BUYLIMIT,Lot,Pivot,0,Pivot-stoploss*poi,HiPrice,NULL,Magic,0,Red);
}
if (HiTime<LoTime && ClPrice<Pivot) {
int ticket8=OrderSend(Symbol(),OP_SELLLIMIT,Lot,Pivot,0,Pivot+stoploss*poi,LoPrice,NULL,Magic,0,Red);
}
}
Hi.
Please write an EA to buy on breach of high of previous candle and sell on breach of low of previous candle.
TP and SL is 15 pips.
When this EA is working on a real account, error 146 is very frequent.
Is it possible to make the Expert Advisor make several attempts to open an order, say, with a pause of half a minute?
Good evening dear programmers! Could you please write an automatic EA without a Stop Loss and Take Profit, which uses one MA and horizontal lines(which can be applied to the chart itself) the algorithm of the advisor: For example, we put on the chart 8 horizontal lines-1.500;1.540;1.580;1.620;1.660, etc....When the MA (5) crosses the line1.500 upwards from below opens Buy (for the first or second bar); Then MA (5) breaks through the bottom line up 1.540 closed previous Buy and reopens Buy; Then MA (5) hesitates back and breaks the line1.540 downwards, closing the previous Buy and open Shell ; ; and so on to infinity ...Respectfully to you ...
МА(5) crosses the line1.500 from below upwards opens Buy (on the first or second bar); Then МА(5) breaks the line1.540 from below upwards, previous Buy is closed and reopens Buy; Then МА(5) after hesitating comes back and breaks the line1.540 downwards, previous Buy is closed and Shell opens .....
.... Г-О-О-О-О-О-О-О-О-Л-Л-Л-Л!!!!!!!!!!!