Page 1 of 1

Candle series and HighLow border color

Posted: Wed Aug 29, 2007 8:31 am
by 13046530
Hello everybody,
I am using TeeChart for .NET version 3.2.2763.26082 and I experienced some problems using Candle series and changing the colour of the High Low border. The first value in the series seems to be drawn well, but as soon as I add a new value or the chart is scroll, the border colour becomes black (it seems a problem of repainting) :( .

This is the piece of code inside InitializeComponents():

Code: Select all

this.candle1.HighLowPen.Color = System.Drawing.Color.Yellow;
this.candle1.LinePen.Color = System.Drawing.Color.FromArgb(((int)(((byte)(122)))), ((int)(((byte)(78)))), ((int)(((byte)(26)))));
this.candle1.Marks.Callout.ArrowHead = Steema.TeeChart.Styles.ArrowHeadStyles.None;
this.candle1.Marks.Callout.ArrowHeadSize = 8;
this.candle1.Marks.Callout.Brush.Color = System.Drawing.Color.Black;
this.candle1.Marks.Callout.Distance = 0;
this.candle1.Marks.Callout.Draw3D = false;
this.candle1.Marks.Callout.Length = 10;
this.candle1.Marks.Callout.Style = Steema.TeeChart.Styles.PointerStyles.Rectangle;
this.candle1.Pointer.Draw3D = false;
this.candle1.Pointer.Style = Steema.TeeChart.Styles.PointerStyles.Rectangle;
this.candle1.Pointer.Visible = true;
this.candle1.Title = "candle1";
this.candle1.UpCloseColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(0)))), ((int)(((byte)(0)))));
this.candle1.XValues.DataMember = "Date";
this.candle1.XValues.DateTime = true;
this.candle1.XValues.Order = Steema.TeeChart.Styles.ValueListOrder.Ascending;
this.candle1.YValues.DataMember = "Close";
.. and this is the code I use to add values to the series

Code: Select all

DateTime timestamp = DateTime.Now;
candle1.Add(timestamp, 50, 90, 30, 70);
candle1.Add(timestamp.AddMinutes(1), 50, 90, 30, 70);
candle1.Add(timestamp.AddMinutes(2), 50, 90, 30, 70);
I also tried to force the border colour through

Code: Select all

candle1.HighLowPen.Color = System.Drawing.Color.Yellow;
before adding any value, but it doesn't work anyway.

Last but not least, which is the functional difference between the HighLow border editor and the SERIES border editor inside the edit window ?

Thanks in advance.

Posted: Wed Aug 29, 2007 10:21 am
by narcis
Hi Luigi,

This works fine here adding the line below to your code.

Code: Select all

			this.candle1.Pen.Color = Color.Yellow;
Last but not least, which is the functional difference between the HighLow border editor and the SERIES border editor inside the edit window ?
The first one sets candle1.HighLowPen while the second sets candle1.Pen.

Posted: Wed Aug 29, 2007 1:44 pm
by 13046530
narcis wrote: This works fine here
Yes it does :) !! Thanks !
narcis wrote: The first one sets candle1.HighLowPen while the second sets candle1.Pen.
Yes, but graphically what does it affect ?
What I'd like to do is having the OpenClose rectangle bound of the same colour of its fill colour (e.g. red) and at the same time I'd like to have the HighLow lines of another color (e.g. Yellow). Practically what I want is to make a red filled rectangle with yellow lines exiting from it...
Is it possible do do this working around Pen and HighLow colour ?

Thanks.

Posted: Thu Aug 30, 2007 9:38 am
by narcis
Hi Luigi,

Ok, this is not working at the moment. You should be able to achieve what you request doing this:

Code: Select all

			this.candle1.Pen.Color = Color.Yellow;
			this.candle1.HighLowPen.Color = System.Drawing.Color.Blue;
However this is not working and I've added the defect (TF02012430) to our bug list to be fixed for next releases.