Ciao ragazzi..
Sto provando a codificare un interno per mostrare Open of the Day corrente sulla finestra e voglio vederlo cambia quando cambia il giorno .. Ho scritto questo indoor (e non sono ancora sicuro che sia giusto
), ma sembra che non cambi quando cambia il giorno. qualcuno può aiutarmi a risolvere questo problema. Grazie.
Codice inserito #property indior_chart_window extern datetime FirstTime = D'1: 00 '; double DayOpen = iOpen (NULL, 0, iBarShift (NULL, 0, FirstTime)); int init () {ObjectCreate (OP, OBJ_LABEL, 0, 0, 0, 0, 0); ObjectSet (OP, OBJPROP_CORNER, 0); ObjectSet (OP, OBJPROP_YDISTANCE, 15); ObjectSet (OP, OBJPROP_XDISTANCE, 200); ObjectSetText (OP,, 5, Arial, CLR_NONE); ritorno (0); } int deinit () {ObjectDelete (OP); ritorno (0); } int start () {ObjectCreate (O, OBJ_LABEL, 0, 0, 0, 0, 0); ObjectSet (O, OBJPROP_CORNER, 0); ObjectSet (O, OBJPROP_YDISTANCE, 20); ObjectSet (O, OBJPROP_XDISTANCE, 5); ObjectSetText (O, Open Price of The Day =, 12, Arial, clrAqua); ObjectSetText (OP, DoubleToStr (DayOpen, 4), 20, Arial Bold, clrRed); ritorno (0); }