![MQL5 - Linguaggio delle strategie di trading integrato nel client terminal MetaTrader 5](https://c.mql5.com/i/registerlandings/logo-2.png)
Ti stai perdendo delle opportunità di trading:
- App di trading gratuite
- Oltre 8.000 segnali per il copy trading
- Notizie economiche per esplorare i mercati finanziari
Registrazione
Accedi
Accetti la politica del sito e le condizioni d’uso
Se non hai un account, registrati
cos'è la funzione "exit" in metatrader?
Voglio "uscire" dall'ontick senza elaborare nulla sotto il...
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();
cos'è la funzione "exit" in metatrader?
Voglio "uscire" dall'ontick senza elaborare nulla sotto il...
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();
Usare "return" (ritorno)
ciao signor mladen
potresti fare MTF+ALERT di questo indicatore
non ridipingere
per quanto riguarda
ciao signor mladen
potresti fare MTF+ALERT di questo indicatore
non ridipingere
per quanto riguarda
Controlla qui: https: //www.mql5.com/en/forum/174980/page39
non funziona. In realtà l'EA dovrebbe essere in grado di selezionare il ticket aperto e chiuderlo quando la condizione è soddisfatta. Cosa potrei migliorare?
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());
}
}
}
signor mladen:
potrebbe aggiungere una freccia sul grafico
per quanto riguarda
Ciao,
Sto studiando questo EA... e mi piace perché ha buoni componenti in esso, ma ho un problema iniziale con esso...
Non so perché mentre è in dopo aver finito il back test, le finestre aperte che tracciano il back test
mostra una "lunga stringa" con i parametri EA... in altri EA che avevo testato, questo non appariva (questo è corretto per me).
Come posso rendere le frecce di questo indicatore più grandi, per favore?
TEAMTRADER