I tried to plot the current CCI value on the chart with this method
...
ObjectCreate(0, "myCCInow", OBJ_LABEL, 0, 0, 0);
ObjectSetString(0, "myCCInow", OBJPROP_TEXT,"CCI @ "+DoubleToString(myCCInow,1));
ObjectSetString(0, "myCCInow", OBJPROP_FONT, font_face);
ObjectSetInteger(0, "myCCInow", OBJPROP_FONTSIZE, font_size);
ObjectSetInteger(0, "myCCInow", OBJPROP_COLOR, White);
ObjectSetInteger(0, "myCCInow", OBJPROP_CORNER, corner);
ObjectSetInteger(0, "myCCInow", OBJPROP_XDISTANCE, 1+distance_x);
ObjectSetInteger(0, "myCCInow", OBJPROP_YDISTANCE, 1+distance_y);
..
unfortunatly it does not return a value which makes sense. Is there a bug in code?
|