Could somebody help me please? I'm trying to draw 2lines in PricePanel, see code sample, but only the last one always appear. I don't know what I'm doing wrong?
Many thanks for any idea how to do it.
jaspee
code sample:
protected override void OnBarUpdate() { // Use this method for calculating your indicator values. Assign a value to each // plot below by replacing 'Close[0]' with your own formula. //Plot0.Set(Close[0]); int startBar = CurrentBar - Bars.GetBar (new DateTime (2015,2,12,19,27,00)); int endBar = CurrentBar - Bars.GetBar (new DateTime (2015,2,12,21,21,00)); int deltaAgo = endBar - startBar; //DrawLine(string tag, int startBarsAgo, double startY, int endBarsAgo, double endY, Color color) if (CurrentBar > 20) { DrawOnPricePanel = true; //DrawLine("tagEntry",5,2082,0,2086,Color.Blue ); DrawLine("tagEntry",true,new DateTime (2015,2,12,19,27,00),Open[startBar],new DateTime (2015,2,12,21,21,00),Close[endBar],Color.Blue ,DashStyle.Dash,3); DrawOnPricePanel = true; DrawLine("tagEntry",true,new DateTime (2015,2,12,19,45,00),Open[startBar],new DateTime (2015,2,12,21,21,00),Close[endBar],Color.Blue ,DashStyle.Dash,3); DrawOnPricePanel = false;
Comment