Help request for this simple alert indicator, why not working at all?
habagobal:
Help request for this simple alert indicator, why not working at all?
I guess it's not an indicator at all. Try to use it as expert. Put it into \experts
forder. Compile and attach this expert.
Help request for this simple alert indicator, why not working at all?
I think using 8 indicators in an alert expert can't be said simple. :)
If everything else is in order, my guest is there is conflicting signals among the indicators.
Why don't you reduce the indicators to one or two, and see if it is working,
then you can add more indicators one by one.
If everything else is in order, my guest is there is conflicting signals among the indicators.
Why don't you reduce the indicators to one or two, and see if it is working,
then you can add more indicators one by one.
I compiled the following EA. It printing-comenting-alerting "OPEN BUY / CLOSE
SELL..." every tick. I am with fireflies about checking "conflicting signals among the indicators"
int start() { double MA_Main,MA_Signal,SAR,MACD_Main,MACD_Signal, Stochastic_Main,Stochastic_Signal,RSI,RSI_Level; string Up,Down,Sound; MA_Main = iMA(NULL,0,5,0,MODE_LWMA,PRICE_CLOSE,0); MA_Signal = iMA(NULL,0,5,0,MODE_LWMA,PRICE_CLOSE,0); SAR = iSAR(NULL,0,0.02,0.2,0); MACD_Main = iMACD(NULL,0,8,17,9,PRICE_CLOSE,MODE_MAIN,0); MACD_Signal = iMACD(NULL,0,8,17,9,PRICE_CLOSE,MODE_SIGNAL,0); Stochastic_Main = iStochastic(NULL,0,8,17,9,MODE_LWMA,1,MODE_MAIN,0); Stochastic_Signal = iStochastic(NULL,0,8,17,9,MODE_LWMA,1,MODE_SIGNAL,0); RSI = iRSI(NULL,0,14,PRICE_CLOSE,0); RSI_Level = 50; Up = "OPEN BUY / CLOSE SELL" +Symbol(); Down = "OPEN SELL / CLOSE BUY" +Symbol(); Sound = "alert2.wav"; { /*if (MA_Main>MA_Signal && SAR<Close[0] && MACD_Main>MACD_Signal && Stochastic_Main>Stochastic_Signal && RSI>RSI_Level)*/ { Alert(Up); Comment(Up); PlaySound(Sound); Print(Up); SendMail("Forex Trading Signal",Up); } return(0); } { if (MA_Main<MA_Signal && SAR>Close[0] && MACD_Main<MACD_Signal && Stochastic_Main<Stochastic_Signal && RSI<RSI_Level) { Alert(Down); Comment(Down); PlaySound(Sound); Print(Down); SendMail("Forex Trading Signal",Down); } return(0); } }
habagobal:
Even just one indicator it doesn't give an alert too. Anyone could fix it ?
Exactly my point, try one indicator first. If this one failed, try ONE other, then ANOTHER. Don't stop with just this one.Even just one indicator it doesn't give an alert too. Anyone could fix it ?
int start() { double MA_Main,MA_Signal; string Up,Down,Sound; MA_Main = iMA(NULL,0,5,0,MODE_LWMA,PRICE_CLOSE,0); MA_Signal = iMA(NULL,0,5,0,MODE_LWMA,PRICE_CLOSE,0); Up = "OPEN BUY / CLOSE SELL : " +Symbol(); Down = "OPEN SELL / CLOSE BUY : " +Symbol(); Sound = "alert2.wav"; if (MA_Main>MA_Signal) { Alert(Up); Comment(Up); PlaySound(Sound); Print(Up); SendMail("Forex Trading Signal",Up); } if (MA_Main<MA_Signal) { Alert(Down); Comment(Down); PlaySound(Sound); Print(Down); SendMail("Forex Trading Signal",Down); } return(0); }
BTW. please read carefully the highlighted lines.
![MQL5 - Language of trade strategies built-in the MetaTrader 5 client terminal](https://c.mql5.com/i/registerlandings/logo-2.png)
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