仕事が完了した
指定
I need an email alert function to be coded for the attached FX5_Divergence indicator. The indicator has been coded to display pop-up alerts which works perfectly ("displayAlert" in the external parameters). I need the option for SendMail as well, if any of the 4 conditions in the code is true.
The requirements are as follows:
A) 2 additional boolean values as external parameters,
1. sendEmailAlert (true/false)
2. MailAlertTimeFilter (true/false)
And additional external parameters to set the time filter in HH:MM format.
B) The indicator has been coded with 4 different alert conditions (can be found in the sections void CatchBullishDivergence and Void CatchBearishDivergence).
If "Classical Bullish Divergence", then send following string: (MT4 terminal time) "Classical bullish divergence in", symbol(), period().
If "Reverse Bullish Divergence", then send following string: (MT4 terminal time) "Reverse bullish divergence in", symbol(), period().
If "Classical Bearish Divergence", then send following string: (MT4 terminal time) "Classical bearish divergence in", symbol(), period().
If "Reverse Bearish Divergence", then send following string: (MT4 terminal time) "Reverse bearish divergence in", symbol(), period().
The indicator will be working on an offline tick chart, so the time reference in the alert should be made to the MT4 terminal time.
C) The time filter for email alert is only influencing sendEmailAlert function. The rest of the indicators functionality must work at all times (pop-up and trendline drawing etc.).
If the time filter for email alert = false, then the alert functions whenever the email alert is set to true.
If time filter for email alert = true, then email alerts will only be sent if there is a signal within a hh:mm - hh:mm interval specified as an external parameter.
This time filter must again reference the MT4 terminal time-stamp, because the indicator mist work on a offline chart with a artificial time-stamp.
Best regards
Tomas