#property copyright "Copyright © 2007, Mark A Flexhaug" #property link "pipaholic@shaw.ca" #property library #import "speak.dll" void gRate(int a0); void gVolume(int a0); void gPitch(int a0); void gSpeak(string a0); #import bool gba_unused_76[100]; int gia_unused_80[100]; double gda_unused_84[100]; string gsa_unused_88[100]; int gia_unused_92[100]; double gda_unused_96[25]; string gsa_100[] = {"None", "Limit", "Stop"}; int gi_unused_104 = 1; int gi_unused_108 = 2; int gi_unused_112 = 1; int gi_unused_116 = 0; int gi_unused_120 = 3; int gi_unused_124 = -1; int gi_128 = -1; int gi_unused_132 = 3; int gi_unused_136 = 2; int gi_unused_140 = 1; int gi_unused_144 = 3; int gi_unused_148 = 2; int gi_unused_152 = 1; int gi_unused_156 = 1; int gi_unused_160 = 2; int gi_unused_164 = 2; int gi_unused_168 = 1; int gi_unused_172 = 2; int gi_unused_176 = 1; int gi_unused_180 = 0; int gi_unused_184 = 1; int gi_unused_188 = 2; int gi_unused_192 = 3; int gi_unused_196 = 4; string gsa_200[] = {"Reset", "Waiting", "In trade", "Closing", "Done Today"}; bool gi_unused_204 = FALSE; bool gi_unused_208 = TRUE; int gi_unused_212 = 60; int gi_unused_216 = 900; int gi_unused_220 = 1800; int gi_unused_224 = 3600; int gi_unused_228 = 5400; int gi_unused_232 = 7200; int gi_unused_236 = 1; int gi_unused_240 = 2; int gi_unused_244 = 3; int gi_unused_248 = 4; int gi_unused_252 = 1; int gi_unused_256 = 0; int gi_unused_260 = 1; int gi_unused_264 = 0; int gi_unused_268 = 1; int gi_unused_272 = 0; int gi_unused_276 = 1; int gi_unused_280 = 0; int gi_unused_284 = 1; int gi_unused_288 = 0; int gi_292 = 1; int gi_unused_296 = 0; int gi_unused_300 = 1; int gi_unused_304 = 0; int gi_unused_308 = 0; int gi_unused_312 = 1; int gi_unused_316 = 0; int gi_unused_320 = 1; int gi_unused_324 = 0; int gi_unused_328 = 1; int gi_unused_332 = 2; int gi_unused_336 = 3; int gi_unused_340 = 1; string gsa_344[] = {"blank", "Waiting", "Preset", "Entry", "Manage"}; string gsa_348[] = {"blank", "SHORT", "LONG", "NEUTRAL"}; string gsa_352[] = {"blank", "Below", "Above"}; string gsa_356[] = {"blank", "Check", "Clear", "Set"}; string gsa_360[] = {"Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday"}; string gsa_364[] = {"Manual", "Auto"}; string gsa_368[] = {"Micro", "Mini", "Standard"}; string gsa_372[] = {"blank", "Short", "Long"}; string gs_dummy_384; string gs_dummy_392; string gsa_400[] = {"Aussie Loonie ", "Aussie Kiwi ", "Aussie Yen ", "Aussie Dollar ", "Swissy Yen", "Euro Aussie", "Euro Loonie", "Euro Swissy", "Euro Pound ", "Euro Yen ", "Euro ", "Pound Swissy ", "Pound Yen ", "Pound ", "Loonie ", "Swissy ", "Dollar Yen ", "Gold ", "Silver ", "Kiwi Yen", "Kiwi Dollar"}; int g_time_404 = 0; int g_count_408 = 0; string Bool2Text(bool ai_0) { if (ai_0) return ("TRUE"); return ("FALSE"); } string BrokerData() { return ("Expert:" + Bool2Text(IsExpertEnabled()) + " LotSize:" + DoubleToStr(MarketInfo(Symbol(), MODE_LOTSIZE), 0) + " TickVal:" + DoubleToStr(MarketInfo(Symbol(), MODE_TICKVALUE), 2) + " TickSize:" + DoubleToStr(MarketInfo(Symbol(), MODE_TICKSIZE), Digits) + " MinLot:" + DoubleToStr(MarketInfo(Symbol(), MODE_MINLOT), 2) + " MaxLot:" + DoubleToStr(MarketInfo(Symbol(), MODE_MAXLOT), 2) + " LotStep:" + DoubleToStr(MarketInfo(Symbol(), MODE_LOTSTEP), 2) + " MarginReq:" + DoubleToStr(MarketInfo(Symbol(), MODE_MARGINREQUIRED), 2) + " Freeze:" + DoubleToStr(MarketInfo(Symbol(), MODE_FREEZELEVEL), 0)); } int CheckEaStatus(bool &aba_0[]) { bool li_ret_4 = TRUE; if (!IsDllsAllowed()) { if (aba_0[90]) MyAlerts(Symbol() + " DLL not allowed ", 1, 0, 0, 0, gi_292); li_ret_4 = FALSE; } else { if (!IsExpertEnabled()) { if (aba_0[90]) MyAlerts(Symbol() + " Expert not enabled ", 1, 0, 0, 0, gi_292); li_ret_4 = FALSE; } else { if (!IsLibrariesAllowed()) { if (aba_0[90]) MyAlerts(Symbol() + " Libraries not allowed ", 1, 0, 0, 0, gi_292); li_ret_4 = FALSE; } else { if (!IsTradeAllowed()) { if (aba_0[90]) MyAlerts(Symbol() + " Trading not allowed ", 0, 0, 0, 0, gi_292); li_ret_4 = FALSE; } else li_ret_4 = TRUE; } } } aba_0[90] = li_ret_4; return (li_ret_4); } int CloseEnough(double ad_0, double ad_8, double ad_16) { bool li_ret_24; if (MathAbs((ad_0 - ad_8) / Point) <= ad_16) li_ret_24 = TRUE; else li_ret_24 = FALSE; return (li_ret_24); } int DoSpread(double a_price_0, double a_price_8, color a_color_16, color a_color_20) { int li_24; int li_28; double ld_40; double ld_48; string l_name_56 = "spreadBar"; if (Period() == PERIOD_M1) { li_24 = 500; li_28 = 750; } else { if (Period() == PERIOD_M5) { li_24 = 1000; li_28 = 2000; } else { if (Period() == PERIOD_M15) { li_24 = 1500; li_28 = 3000; } else { if (Period() == PERIOD_M30) { li_24 = 2000; li_28 = 8000; } else { if (Period() == PERIOD_H1) { li_24 = 4000; li_28 = 12000; } else { li_24 = 15000; li_28 = 50000; } } } } } if (Symbol() == "GBPUSDm" || Symbol() == "GBPUSD") { ld_40 = 4; ld_48 = 6; } else { if (Symbol() == "GBPJPYm" || Symbol() == "GBPJPY") { ld_40 = 10; ld_48 = 13; } else { if (Symbol() == "EURJPYm" || Symbol() == "EURJPY") { ld_40 = 4; ld_48 = 6; } else { if (Symbol() == "EURUSDm" || Symbol() == "EURUSD") { ld_40 = 3; ld_48 = 5; } else { if (Symbol() == "USDCHFm" || Symbol() == "USDCHF") { ld_40 = 5; ld_48 = 7; } else { if (Symbol() == "USDJPYm" || Symbol() == "USDJPY") { ld_40 = 4; ld_48 = 6; } else { if (Symbol() == "USDCADm" || Symbol() == "USDCAD") { ld_40 = 5; ld_48 = 7; } else { if (Symbol() == "EURGBPm" || Symbol() == "EURGBP") { ld_40 = 4; ld_48 = 6; } } } } } } } } double ld_32 = NormalizeDouble((a_price_8 - a_price_0) / Point, Digits); ObjectDelete(l_name_56); ObjectCreate(l_name_56, OBJ_RECTANGLE, 0, Time[0] + li_24, a_price_8, Time[0] + (li_24 + li_28), a_price_0); if (ld_32 <= ld_40) ObjectSet(l_name_56, OBJPROP_COLOR, a_color_16); else { if (ld_32 > ld_40 && ld_32 <= ld_48) ObjectSet(l_name_56, OBJPROP_COLOR, Yellow); else if (ld_32 > ld_48) ObjectSet(l_name_56, OBJPROP_COLOR, Red); } ObjectDelete(l_name_56 + "val"); ObjectCreate(l_name_56 + "val", OBJ_TEXT, 0, Time[0] + (li_24 + li_28 - li_24 / 2), a_price_0); ObjectSetText(l_name_56 + "val", DoubleToStr(ld_32, 0), 12, "Arial Bold", a_color_20); ObjectsRedraw(); return (0); } string DoubleArrayToStr(double ada_0[], int ai_4) { string l_str_concat_12 = ""; for (int l_index_8 = 0; l_index_8 < ai_4; l_index_8++) l_str_concat_12 = StringConcatenate(l_str_concat_12, " ", ada_0[l_index_8]); return (l_str_concat_12); } int drawLine(string a_name_0, int a_datetime_8, double a_price_12, int a_datetime_20, int a_width_24, color a_color_28) { ObjectDelete(a_name_0); ObjectCreate(a_name_0, OBJ_TREND, 0, a_datetime_8, a_price_12, a_datetime_20, a_price_12, 0, 0); ObjectSet(a_name_0, OBJPROP_COLOR, a_color_28); ObjectSet(a_name_0, OBJPROP_RAY, FALSE); ObjectSet(a_name_0, OBJPROP_WIDTH, a_width_24); ObjectSet(a_name_0, OBJPROP_STYLE, STYLE_SOLID); return (0); } int DrawSeg(string a_name_0, int a_datetime_8, double a_price_12, int a_datetime_20, double a_price_24, int a_width_32, color a_color_36) { ObjectDelete(a_name_0); ObjectCreate(a_name_0, OBJ_TREND, 0, a_datetime_8, a_price_12, a_datetime_20, a_price_24, 0, 0); ObjectSet(a_name_0, OBJPROP_COLOR, a_color_36); ObjectSet(a_name_0, OBJPROP_RAY, FALSE); ObjectSet(a_name_0, OBJPROP_WIDTH, a_width_32); ObjectSet(a_name_0, OBJPROP_STYLE, STYLE_SOLID); return (0); } int drawText(string a_name_0, int a_datetime_8, double a_price_12, string a_text_20, color a_color_28, int a_fontsize_32) { ObjectDelete(a_name_0); ObjectCreate(a_name_0, OBJ_TEXT, 0, a_datetime_8, a_price_12); ObjectSetText(a_name_0, a_text_20, a_fontsize_32, "Arial Bold", a_color_28); return (0); } int GetDailyRange(int ai_0, int /**/ ai_unused_4) { double l_ihigh_28; double l_ilow_36; bool li_8 = FALSE; int l_index_12 = 0; int l_count_16 = 0; double ld_ret_44 = 0; int l_day_20 = TimeDay(Time[0]); int l_day_24 = l_day_20; while (!li_8) { if (TimeDay(Time[l_index_12]) != l_day_24 && TimeDayOfWeek(Time[l_index_12]) != 0) { l_ihigh_28 = iHigh(Symbol(), PERIOD_D1, iBarShift(Symbol(), PERIOD_D1, Time[l_index_12])); l_ilow_36 = iLow(Symbol(), PERIOD_D1, iBarShift(Symbol(), PERIOD_D1, Time[l_index_12])); ld_ret_44 += (l_ihigh_28 - l_ilow_36) / Point; l_count_16++; if (l_count_16 == ai_0) li_8 = TRUE; } l_day_24 = TimeDay(Time[l_index_12]); if (l_index_12 < Bars - 1) l_index_12++; else li_8 = TRUE; } ld_ret_44 /= ai_0; return (ld_ret_44); } int GetMonthlyRange(int ai_0, int /**/ ai_unused_4) { double l_ihigh_28; double l_ilow_36; bool li_8 = FALSE; int l_index_12 = 0; int l_count_16 = 0; double ld_ret_44 = 0; if (ai_0 == 0) return (0); int l_month_20 = TimeMonth(Time[0]); int l_month_24 = l_month_20; while (!li_8) { if (TimeMonth(Time[l_index_12]) != l_month_24) { l_ihigh_28 = iHigh(Symbol(), PERIOD_MN1, iBarShift(Symbol(), PERIOD_MN1, Time[l_index_12])); l_ilow_36 = iLow(Symbol(), PERIOD_MN1, iBarShift(Symbol(), PERIOD_MN1, Time[l_index_12])); ld_ret_44 += (l_ihigh_28 - l_ilow_36) / Point; l_count_16++; if (l_count_16 == ai_0) li_8 = TRUE; } l_month_24 = TimeMonth(Time[l_index_12]); if (l_index_12 < Bars - 1) l_index_12++; else li_8 = TRUE; } ld_ret_44 /= ai_0; return (ld_ret_44); } int GetPair(string as_0) { int li_ret_8; if (as_0 == "AUDCADm" || as_0 == "AUDCAD" || as_0 == "AUDCAD.") li_ret_8 = 0; else { if (as_0 == "AUDNZDm" || as_0 == "AUDNZD" || as_0 == "AUDNZD.") li_ret_8 = 1; else { if (as_0 == "AUDJPYm" || as_0 == "AUDJPY" || as_0 == "AUDJPY.") li_ret_8 = 2; else { if (as_0 == "AUDUSDm" || as_0 == "AUDUSD" || as_0 == "AUDUSD.") li_ret_8 = 3; else { if (as_0 == "CHFJPYm" || as_0 == "CHFJPY" || as_0 == "CHFJPY.") li_ret_8 = 4; else { if (as_0 == "EURAUDm" || as_0 == "EURAUD" || as_0 == "EURAUD.") li_ret_8 = 5; else { if (as_0 == "EURCADm" || as_0 == "EURCAD" || as_0 == "EURCAD.") li_ret_8 = 6; else { if (as_0 == "EURCHFm" || as_0 == "EURCHF" || as_0 == "EURCHF.") li_ret_8 = 7; else { if (as_0 == "EURGBPm" || as_0 == "EURGBP" || as_0 == "EURGBP.") li_ret_8 = 8; else { if (as_0 == "EURJPYm" || as_0 == "EURJPY" || as_0 == "EURJPY.") li_ret_8 = 9; else { if (as_0 == "EURUSDm" || as_0 == "EURUSD" || as_0 == "EURUSD.") li_ret_8 = 10; else { if (as_0 == "GBPCHFm" || as_0 == "GBPCHF" || as_0 == "GBPCHF.") li_ret_8 = 11; else { if (as_0 == "GBPJPYm" || as_0 == "GBPJPY" || as_0 == "GBPJPY.") li_ret_8 = 12; else { if (as_0 == "GBPUSDm" || as_0 == "GBPUSD" || as_0 == "GBPUSD.") li_ret_8 = 13; else { if (as_0 == "USDCADm" || as_0 == "USDCAD" || as_0 == "USDCAD.") li_ret_8 = 14; else { if (as_0 == "USDCHFm" || as_0 == "USDCHF" || as_0 == "USDCHF.") li_ret_8 = 15; else { if (as_0 == "USDJPYm" || as_0 == "USDJPY" || as_0 == "USDJPY.") li_ret_8 = 16; else { if (as_0 == "XAUUSDm" || as_0 == "XAUUSD" || as_0 == "XAUUSD.") li_ret_8 = 17; else { if (as_0 == "XAGUSDm" || as_0 == "XAGUSD" || as_0 == "XAGUSD.") li_ret_8 = 18; else { if (as_0 == "GOLD" || as_0 == "GOLD" || as_0 == "GOLD.") li_ret_8 = 17; else { if (as_0 == "SILVER" || as_0 == "SILVER" || as_0 == "SILVER.") li_ret_8 = 18; else { if (as_0 == "NZDJPYm" || as_0 == "NZDJPY" || as_0 == "NZDJPY.") li_ret_8 = 19; else if (as_0 == "NZDUSDm" || as_0 == "NZDUSD" || as_0 == "NZDUSD.") li_ret_8 = 20; } } } } } } } } } } } } } } } } } } } } } return (li_ret_8); } string IntArrayToStr(int aia_0[], int ai_4) { string l_str_concat_12 = ""; for (int l_index_8 = 0; l_index_8 < ai_4; l_index_8++) l_str_concat_12 = StringConcatenate(l_str_concat_12, " ", aia_0[l_index_8]); return (l_str_concat_12); } int IsInWindow(string as_0, string as_8) { int l_datetime_16 = TimeCurrent(); if (l_datetime_16 >= StrToTime(as_0) && l_datetime_16 < StrToTime(as_8)) return (1); return (0); } int Log(string as_0, string as_8, int ai_16) { int l_error_24; string ls_40 = TimeToStr(TimeCurrent(), TIME_MINUTES|TIME_SECONDS) + " - "; if (ai_16 > 0) for (int l_count_20 = 0; l_count_20 < ai_16; l_count_20++) ls_40 = StringConcatenate(ls_40, "\t"); ls_40 = StringConcatenate(ls_40, as_8, "\n"); string l_str_concat_32 = StringConcatenate(as_0, ".log"); int l_file_28 = FileOpen(l_str_concat_32, FILE_BIN|FILE_WRITE|FILE_READ); if (l_file_28 > 0) { l_error_24 = GetLastError(); FileSeek(l_file_28, 0, SEEK_END); FileWriteString(l_file_28, ls_40, StringLen(ls_40)); if (l_error_24 > 0/* NO_ERROR */ && l_error_24 != 4200/* OBJECT_ALREADY_EXISTS */) Print("Log File Error : ", l_error_24); } FileClose(l_file_28); return (0); } int MyAlerts(string as_0, bool ai_8, bool ai_12, bool ai_16, bool ai_20, bool ai_24) { string ls_unused_80; string l_str_concat_88; string ls_96; string ls_unused_28 = "=== Speech Variables ==="; int li_unused_36 = 1; bool li_40 = TRUE; int li_44 = 100; bool li_48 = FALSE; int l_global_var_52 = 0; string ls_56 = Symbol(); string ls_unused_64 = Period(); string ls_unused_72 = Hour() + Minute() + Seconds(); string l_var_name_104 = "$AlarmBlock"; if (GlobalVariableCheck(l_var_name_104)) l_global_var_52 = GlobalVariableGet(l_var_name_104); else GlobalVariableSet(l_var_name_104, 0); if (l_global_var_52 > 0) return (0); if (ai_8) Alert(as_0); if (ai_12) SendMail(as_0, as_0); if (ai_16) { gRate(li_40); gVolume(li_44); gPitch(li_48); gSpeak(as_0); } if (ai_20) { l_str_concat_88 = StringConcatenate(as_0, ".gif"); WindowScreenShot(l_str_concat_88, 640, 480); if (ai_8) Alert(Symbol(), " Snapshot taken"); } if (ai_24) { ls_96 = TimeToStr(TimeLocal(), TIME_DATE) + " - " + Symbol() + " - Alert"; Log(ls_96, as_0, 0); } return (0); } int MyComment(bool ai_0, int a_corner_4, int ai_8, string a_text_12, string a_text_20, color a_color_28, color a_color_32, int ai_36) { int l_fontsize_48; int l_x_60; int l_x_64; int li_40 = 10; int l_fontsize_44 = 10; int li_52 = 15; if (ai_36 > li_40) l_fontsize_48 = ai_36; else l_fontsize_48 = li_40; if (a_corner_4 == 0 || a_corner_4 == 2) { l_x_60 = 5; l_x_64 = 100; } else { l_x_60 = 70; l_x_64 = 5; } int l_y_56 = ai_8 * li_52; if (ai_0) { ObjectCreate("cL" + a_corner_4 + ai_8, OBJ_LABEL, 0, 0, 0); ObjectSetText("cL" + a_corner_4 + ai_8, a_text_12, l_fontsize_44, "Arial Bold", a_color_28); ObjectSet("cL" + a_corner_4 + ai_8, OBJPROP_CORNER, a_corner_4); ObjectSet("cL" + a_corner_4 + ai_8, OBJPROP_XDISTANCE, l_x_60); ObjectSet("cL" + a_corner_4 + ai_8, OBJPROP_YDISTANCE, l_y_56); ObjectCreate("cD" + a_corner_4 + ai_8, OBJ_LABEL, 0, 0, 0); ObjectSet("cD" + a_corner_4 + ai_8, OBJPROP_CORNER, a_corner_4); ObjectSet("cD" + a_corner_4 + ai_8, OBJPROP_XDISTANCE, l_x_64); ObjectSet("cD" + a_corner_4 + ai_8, OBJPROP_YDISTANCE, l_y_56); } ObjectSetText("cD" + a_corner_4 + ai_8, a_text_20, l_fontsize_48, "Arial Bold", a_color_32); ObjectsRedraw(); return (0); } int MySleep(int ai_0) { int l_datetime_8; bool li_4 = FALSE; int l_datetime_12 = TimeLocal(); while (!li_4) { l_datetime_8 = TimeLocal(); if (l_datetime_8 >= l_datetime_12 + ai_0) li_4 = TRUE; else Sleep(500); } return (0); } int MyTable(int a_window_0, int a_corner_4, int a_y_8, int a_x_12, string a_text_16, string a_fontname_24, color a_color_32, int ai_36, bool ai_40) { int l_fontsize_48; int li_44 = 6; if (ai_36 > li_44) l_fontsize_48 = ai_36; else l_fontsize_48 = li_44; if (ai_40) { ObjectCreate("table" + a_window_0 + a_corner_4 + a_y_8 + a_x_12, OBJ_LABEL, a_window_0, 0, 0); ObjectSet("table" + a_window_0 + a_corner_4 + a_y_8 + a_x_12, OBJPROP_CORNER, a_corner_4); ObjectSet("table" + a_window_0 + a_corner_4 + a_y_8 + a_x_12, OBJPROP_XDISTANCE, a_x_12); ObjectSet("table" + a_window_0 + a_corner_4 + a_y_8 + a_x_12, OBJPROP_YDISTANCE, a_y_8); } ObjectSetText("table" + a_window_0 + a_corner_4 + a_y_8 + a_x_12, a_text_16, l_fontsize_48, a_fontname_24, a_color_32); return (0); } int NewBar() { if (Time[0] != g_time_404) { g_time_404 = Time[0]; return (1); } return (0); } int PlaceChar(int a_window_0, int a_corner_4, int a_x_8, int a_y_12, int a_angle_16, string a_text_20, color a_color_28, int ai_32, string a_fontname_36) { int l_fontsize_52; int li_44 = 10; int li_unused_48 = 10; int li_unused_56 = 15; if (ai_32 > li_44) l_fontsize_52 = ai_32; else l_fontsize_52 = li_44; ObjectDelete("pc" + a_x_8 + a_y_12); if (a_corner_4 != gi_128) { ObjectCreate("pc" + a_corner_4 + a_x_8 + a_y_12, OBJ_LABEL, a_window_0, 0, 0); ObjectSetText("pc" + a_corner_4 + a_x_8 + a_y_12, a_text_20, l_fontsize_52, a_fontname_36, a_color_28); ObjectSet("pc" + a_corner_4 + a_x_8 + a_y_12, OBJPROP_CORNER, a_corner_4); ObjectSet("pc" + a_corner_4 + a_x_8 + a_y_12, OBJPROP_XDISTANCE, a_x_8); ObjectSet("pc" + a_corner_4 + a_x_8 + a_y_12, OBJPROP_YDISTANCE, a_y_12); ObjectSet("pc" + a_corner_4 + a_x_8 + a_y_12, OBJPROP_ANGLE, a_angle_16); } return (0); } int RevProb(string as_unused_0, double ad_8, double ad_16) { int li_ret_24; double ld_28 = MathAbs(ad_8 - ad_16) / Point; if (ld_28 <= 9.0) li_ret_24 = 75; else { if (ld_28 >= 10.0 && ld_28 <= 19.0) li_ret_24 = 55; else { if (ld_28 >= 20.0 && ld_28 <= 29.0) li_ret_24 = 40; else { if (ld_28 >= 30.0 && ld_28 <= 39.0) li_ret_24 = 25; else { if (ld_28 >= 40.0 && ld_28 <= 49.0) li_ret_24 = 13; else { if (ld_28 >= 50.0 && ld_28 <= 59.0) li_ret_24 = 8; else { if (ld_28 >= 60.0 && ld_28 <= 69.0) li_ret_24 = 4; else li_ret_24 = 1; } } } } } } return (li_ret_24); } string Sleeping(string a_str_concat_0) { a_str_concat_0 = StringConcatenate(a_str_concat_0, "z"); if (g_count_408 < 4) g_count_408++; else { g_count_408 = 0; a_str_concat_0 = "z"; } return (a_str_concat_0); } int SymData(string a_symbol_0, double &ada_8[], bool ai_12) { if (ai_12) { ada_8[0] = MarketInfo(a_symbol_0, MODE_LOTSIZE); ada_8[1] = MarketInfo(a_symbol_0, MODE_TICKVALUE); ada_8[2] = MarketInfo(a_symbol_0, MODE_TICKSIZE); ada_8[3] = MarketInfo(a_symbol_0, MODE_MINLOT); ada_8[4] = MarketInfo(a_symbol_0, MODE_MAXLOT); ada_8[5] = MarketInfo(a_symbol_0, MODE_LOTSTEP); ada_8[6] = MarketInfo(a_symbol_0, MODE_MARGINREQUIRED); ada_8[7] = MarketInfo(a_symbol_0, MODE_FREEZELEVEL); ada_8[12] = MarketInfo(a_symbol_0, MODE_DIGITS); ada_8[11] = MarketInfo(a_symbol_0, MODE_POINT); } ada_8[8] = MarketInfo(a_symbol_0, MODE_SPREAD); ada_8[9] = MarketInfo(a_symbol_0, MODE_BID); ada_8[10] = MarketInfo(a_symbol_0, MODE_ASK); return (0); } int WaterMark(string a_name_0, string a_text_8, int a_window_16, int a_corner_20, color a_color_24) { int l_x_28 = 10; int l_y_32 = 2; ObjectCreate(a_name_0, OBJ_LABEL, a_window_16, 0, 0); ObjectSetText(a_name_0, a_text_8, 10, "Times New Roman Bold Italic", a_color_24); ObjectSet(a_name_0, OBJPROP_CORNER, a_corner_20); ObjectSet(a_name_0, OBJPROP_XDISTANCE, l_x_28); ObjectSet(a_name_0, OBJPROP_YDISTANCE, l_y_32); ObjectsRedraw(); return (0); }