(NEED HELP) Adding Arrows and Alert Code for This GOOD TMA

 

Currently I am planning to Manual Trade With this Indicator Rules, but I have some problems to be solved.. I need Help from this Forum.

I hope This Indicator also helping The others to trade.

Rules
- Arrows and Alert Showing When The Price Crossing The Gold band

IF possible,
The Arrows and Alert Only showing Sell When The Middle Band Is Red.
The Arrows and Alert Only showing Buy When The Middle band Is Green.

Thankyou

Need Help add arrows and alert coding for this This Indicator

Files:
 
Muhammad Ichsan Hakim: but I have some problems to be solved.. I need Help from this Forum.
  1. Help you with what? You haven't stated a problem, you haven't even stated a want. Show us your attempt (using the CODE button) and state the nature of your problem.
              No free help 2017.04.21

    MT4: Learn to code it.
    MT5: Begin learning to code it.
    If you don't learn MQL4/5, there is no common language for us to communicate. If we tell you what you need, you can't code it. If we give you the code, you don't know how to integrate it into your code.

    or pay (Freelance) someone to code it. Top of every page is the link Code Base.
              Hiring to write script - General - MQL5 programming forum 2019.08.21

    We're not going to code it for you (although it could happen if you are lucky or the problem is interesting.) We are willing to help you when you post your attempt (using CODE button) and state the nature of your problem.
              No free help 2017.04.21

  2. Muhammad Ichsan Hakim:
    The Arrows and Alert Only showing Sell When The Middle Band Is Red.
    The Arrows and Alert Only showing Buy When The Middle band Is Green.

    Don't modify the indicator, write a new indicator/EA to do that.

 
Muhammad Ichsan Hakim:

Currently I am planning to Manual Trade With this Indicator Rules, but I have some problems to be solved.. I need Help from this Forum.

I hope This Indicator also helping The others to trade.

Rules
- Arrows and Alert Showing When The Price Crossing The Gold band

IF possible,
The Arrows and Alert Only showing Sell When The Middle Band Is Red.
The Arrows and Alert Only showing Buy When The Middle band Is Green.

Thankyou

This "This GOOD TMA" recalculate/repaint,be care of its this behaviour in case you do not know already

 
mntiwana:

This "This GOOD TMA" recalculate/repaint,be care of its this behaviour in case you do not know already

Thanks for your information

currently I trade on short only sir.

I hope anyone can helpme solving this.

 
William Roeder:
  1. Help you with what? You haven't stated a problem, you haven't even stated a want. Show us your attempt (using the CODE button) and state the nature of your problem.
              No free help 2017.04.21

    MT4: Learn to code it.
    MT5: Begin learning to code it.
    If you don't learn MQL4/5, there is no common language for us to communicate. If we tell you what you need, you can't code it. If we give you the code, you don't know how to integrate it into your code.

    or pay (Freelance) someone to code it. Top of every page is the link Code Base.
              Hiring to write script - General - MQL5 programming forum 2019.08.21

    We're not going to code it for you (although it could happen if you are lucky or the problem is interesting.) We are willing to help you when you post your attempt (using CODE button) and state the nature of your problem.
              No free help 2017.04.21

  2. Don't modify the indicator, write a new indicator/EA to do that.

void manageAlerts()
{
   if (alertsOn)
   { 
      int trend;        
      if (Close[0] > upperBand[0]) trend =  1;
      else if (Close[0] < lowerBand[0]) trend = -1;
      else {AlertHappened = false;}
            
      if (!AlertHappened && AlertTime != Time[0])
      {       
         if (trend == 1) doAlert("up");
         if (trend ==-1) doAlert("down");
      }         
   }
}


void doAlert(string doWhat)
{ 
   if (AlertHappened) return;
   AlertHappened = true;
   AlertTime = Time[0];
   string message;
     
   message =  StringConcatenate(Symbol()," at ",TimeToStr(TimeLocal(),TIME_SECONDS)," "+TimeFrameValueToString(TimeFrameValue)+" TMA bands price penetrated ",doWhat," band");
   if (alertsMessage) Alert(message);
   if (alertsEmail)   SendMail(StringConcatenate(Symbol(),"TMA bands "),message);
   if (alertsSound)   PlaySound("alert2.wav");

}

Above is the code that not shown on indicator when the rules apply.

current price crossing Upper Band / Lower Band
the doAlert not yet showing me signal on Backtest, I am struggling with that brother,

thanks for your concern, I am very new to this forum

 
Muhammad Ichsan Hakim: current price crossing Upper Band / Lower Band
  1. Where do you test for that?
  2. Drop your AlertHappened. It does nothing that AlertTime doesn't already do.
Reason: