05.03.21
|
Mitglied
|
|
Registriert seit: Feb 2014
Ort: Berlin
Beiträge: 42
|
|
Zitat:
Zitat von Sirocool
ich schaue mir mal den mq4 code von der seite an und teste das mit den ok.
|
Also ich habe mal dein MQ5 mit dem Mq4 Code verglichen
Zitat:
Mq4 ist das drin input string SoundFileName = "alert.wav"; als auswahl im menu schon im Indicator was der mq5 nicht drin hat
und sieht da dann so aus
if ((i == 2) && (LastAlertTime != Time[1]))
{
if ((ExtMapBuffer1[i] == EMPTY_VALUE) && (ExtMapBuffer1[i - 1] == bbMACD[i - 1]))
{
string Text = Symbol() + " - " + EnumToString((ENUM_TIMEFRAMES)Period()) + " - BB_MACD: from DOWN to UP @ " + TimeToString(Time[1]) + ".";
if (EnableNativeAlerts) Alert(Text);
if (EnableEmailAlerts) SendMail(Text, Text);
if (EnableSoundAlerts) PlaySound(SoundFileName);
if (EnablePushAlerts) SendNotification(Text);
LastAlertTime = Time[1];
}
else if ((ExtMapBuffer2[i] == EMPTY_VALUE) && (ExtMapBuffer2[i - 1] == bbMACD[i - 1]))
{
string Text = Symbol() + " - " + EnumToString((ENUM_TIMEFRAMES)Period()) + " - BB_MACD: from UP to DOWN @ " + TimeToString(Time[1]) + ".";
if (EnableNativeAlerts) Alert(Text);
if (EnableEmailAlerts) SendMail(Text, Text);
if (EnableSoundAlerts) PlaySound(SoundFileName);
if (EnablePushAlerts) SendNotification(Text);
LastAlertTime = Time[1];
}
}
ExtMapBuffer3[i] = avg + (StDv * sDev);
ExtMapBuffer4[i] = avg - (StDv * sDev);
}
|
|