{求助}提醒不断重复
/*
Generated by EX4-TO-MQ4 decompiler V4.0.224.1 []
Website: http://purebeam.biz
E-mail : purebeam@gmail.com
*/
#property indicator_chart_window
#property indicator_buffers 2
#property indicator_color1 DeepPink
#property indicator_color2 DodgerBlue
double g_ibuf_76[];
double g_ibuf_80[];
extern bool VoiceAlert = FALSE;
int init() {
ObjectCreate("June", OBJ_LABEL, 0, 0, 0);
ObjectSet("June", OBJPROP_CORNER, 4);
ObjectSet("June", OBJPROP_XDISTANCE, 0);
ObjectSet("June", OBJPROP_YDISTANCE, 15);
ObjectSet("June", OBJPROP_BACK, TRUE);
ObjectSetText("June", " ", 14, "Verdana", Lime);
SetIndexStyle(0, DRAW_ARROW, EMPTY, 2);
SetIndexArrow(0, 104);
SetIndexBuffer(0, g_ibuf_76);
SetIndexStyle(1, DRAW_ARROW, EMPTY, 2);
SetIndexArrow(1, 104);
SetIndexBuffer(1, g_ibuf_80);
return (0);
}
int deinit() {
return (0);
}
int start() {
int li_0;
double l_ima_4;
double l_ima_12;
double l_ima_20;
double l_ima_28;
double l_ima_36;
double l_ima_44;
double l_ima_52;
double l_ima_60;
double ld_68;
double ld_76;
int li_84 = IndicatorCounted();
if (li_84 < 0) return (-1);
if (li_84 > 0) li_84--;
int li_88 = Bars - li_84;
for (int li_92 = 0; li_92 <= li_88; li_92++) {
li_0 = li_92;
ld_68 = 0;
ld_76 = 0;
for (li_0 = li_92; li_0 <= li_92 + 9; li_0++) ld_76 += MathAbs(High - Low);
ld_68 = ld_76 / 10.0;
l_ima_4 = iMA(NULL, 0, 14, 0, MODE_LWMA, PRICE_MEDIAN, li_92);
l_ima_12 = iMA(NULL, 0, 55, 0, MODE_LWMA, PRICE_MEDIAN, li_92);
l_ima_20 = iMA(NULL, 0, 1, 0, MODE_LWMA, PRICE_CLOSE, li_92);
l_ima_36 = iMA(NULL, 0, 3, 0, MODE_LWMA, PRICE_CLOSE, li_92 + 1);
l_ima_52 = iMA(NULL, 0, 3, 0, MODE_LWMA, PRICE_CLOSE, li_92 - 1);
l_ima_28 = iMA(NULL, 0, 5, 0, MODE_LWMA, PRICE_OPEN, li_92);
l_ima_44 = iMA(NULL, 0, 5, 0, MODE_LWMA, PRICE_OPEN, li_92 + 1);
l_ima_60 = iMA(NULL, 0, 5, 0, MODE_LWMA, PRICE_OPEN, li_92 - 1);
if ((High + Low) / 2.0 < l_ima_12 && (High + Low) / 2.0 < l_ima_4 && l_ima_20 > l_ima_28 && l_ima_36 < l_ima_44 && l_ima_52 > l_ima_60) {
g_ibuf_76 = Low - ld_68 / 2.0;
if (VoiceAlert == TRUE) Alert("Moving Average has crossed up");
} else {
if ((High + Low) / 2.0 > l_ima_12 && (High + Low) / 2.0 > l_ima_4 && l_ima_20 < l_ima_28 && l_ima_36 > l_ima_44 && l_ima_52 < l_ima_60) {
g_ibuf_80 = High + ld_68 / 2.0;
if (VoiceAlert == TRUE) Alert("Moving Average has crossed down");
}
}
}
return (0);
}
提醒按钮开了就无限提醒,为什么这样啊
楼主辛苦了 好好 学习了 确实不错 学习了,不错,讲的太有道理了 学习了,不错 学习了,不错 学习了,不错 帮你顶下哈!! {:1_181:} 谢谢
页:
[1]
2