Coding help - page 714

 
THANKS
 

what is the "exit" function in metatrader ?

 I want to "quit" the ontick without processing nothing below the...

 

void OnTick(){


  bool RoboON = false;

   if (checkTimeLimits(StartHour1,StartMinute1,EndHour1,EndMinute1,TimeCurrent()))

   RoboON = true;

   if (checkTimeLimits(StartHour2,StartMinute2,EndHour2,EndMinute2,TimeCurrent()))

   RoboON = true;

   

   if (RoboON) 

   Exit;  <=====  what is "exit" function that abort the rest of procedure ?

   //ExtExpert.OnTick(); 


 
baraozemo:

what is the "exit" function in metatrader ?

 I want to "quit" the ontick without processing nothing below the...

 

void OnTick(){


  bool RoboON = false;

   if (checkTimeLimits(StartHour1,StartMinute1,EndHour1,EndMinute1,TimeCurrent()))

   RoboON = true;

   if (checkTimeLimits(StartHour2,StartMinute2,EndHour2,EndMinute2,TimeCurrent()))

   RoboON = true;

   

   if (RoboON) 

   Exit;  <=====  what is "exit" function that abort the rest of procedure ?

   //ExtExpert.OnTick(); 


Use "return"

 

hi mr mladen

could you make MTF+ALERT of this indicator

it not repaint

regard 

Files:
 
bilbao:

hi mr mladen

could you make MTF+ALERT of this indicator

it not repaint

regard 

Check here : https://www.mql5.com/en/forum/174980/page39
 
thanks very much mr mladen
 
Hi Pro-Coders,

I wonder if someone could help. For some reason my SIGNAL_CLOSEBUY and SIGNAL_CLOSESELL

condition is not working. Actually the EA should be able to select the open ticket and close it when the condition is fulfilled. What could I improve?

sell_ticket=OrderSend(Symbol(),OP_SELL,LotsOptimized(),
NormalizeDouble(Bid,digit),
Slippage*PipMultiplier,0,0,
"Sell(#"+MagicNumber+")",MagicNumber,0,Red); // SELL Ticket
                                                                                                                  

buy_ticket=OrderSend(Symbol(),OP_BUY,LotsOptimized(),                           NormalizeDouble(Ask,digit),                                                      Slippage*PipMultiplier,0,0,                                                      "Buy(#"+MagicNumber+")",MagicNumber,0,Green);
                                                                          
  //+------------------------------------------------------------------+
  // CloseBUY RSI<45
  //+------------------------------------------------------------------+
  
  if(RSIfilter<45) Order=SIGNAL_CLOSEBUY;
  //if(Order==SIGNAL_CLOSEBUY && buy_ticket!=0)
  if(Order==SIGNAL_CLOSEBUY && buy_ticket!=0 && ((EachTickMode && !TickCheck) ||   (!EachTickMode && (Bars!=BarCount))))
                 {
                  if(OrderSelect(buy_ticket,SELECT_BY_TICKET))
                    {
                     dummyResult=OrderClose(OrderTicket(),OrderLots(),Bid,Slippage*PipMultiplier,MediumSeaGreen);
                     if(EachTickMode) TickCheck = True;
                     if(!EachTickMode) BarCount = Bars;
                     Print("Error closing Buy #",(string)OrderTicket()," Error code ",(string)GetLastError());
                    }
                 }
               else

   //+------------------------------------------------------------------+
   // CloseSELL RSI>55    
   //+------------------------------------------------------------------+
   if(RSIfilter>55) Order=SIGNAL_CLOSESELL;
   //if(Order==SIGNAL_CLOSESELL && sell_ticket!=0)
   if(Order==SIGNAL_CLOSESELL && sell_ticket!=0 &&((EachTickMode && !TickCheck) || (!EachTickMode && (Bars!=BarCount))))  
                
                 {
                  if(OrderSelect(sell_ticket,SELECT_BY_TICKET))
                    {
                     dummyResult=OrderClose(OrderTicket(),OrderLots(),Ask,Slippage*PipMultiplier,DarkOrange);
                     if(EachTickMode) TickCheck = True;
                     if(!EachTickMode) BarCount = Bars;
                     Print("Error closing Sell #",(string)OrderTicket()," Error code ",(string)GetLastError());
                    }
                 }

              }

 

 

mr mladen:

could you add arrow on chart

regard 

 

Hi,

I'm studding this EA.. and I like it because have good components in it, but I have a initial problem with it..

I don't know why while it is in after finished the back test,  the opened widows that plots the back test

show a "long string" with the EA parameters...  in anthers EA that I had tested , this didn't appear  (that is the correct to me).


Files:
starter2.mq5  17 kb
 

How can I make the arrows on this indicator a bigger size please?

TEAMTRADER

Reason: