Page 1 of 1
pointer color style
Posted: Sat Oct 01, 2011 12:53 pm
by 14051412
Hi Forum
Im plotting a curve with point style "cross" and another with style "star" and I want to change the color of the point style because always is black; but I couldn't do it.
When the style if a shape i can change the color with
line.Pointer.Color = Color.red
but it dont work for the style "cross", "star" and "dot". I need do it by code, no for the editor.
How can I do it?
Thankyou
Re: pointer color style
Posted: Mon Oct 03, 2011 8:40 am
by 10050769
Hello lolo,
Using last version of Teechart.Net and next code, your problem doesn't appears:
Steema.TeeChart.Styles.Line series1,series2;
Code: Select all
private void InitializeChart()
{
tChart1.Aspect.View3D = false;
series1 = new Line(tChart1.Chart);
series2 = new Line(tChart1.Chart);
series1.Pointer.Visible = true;
series2.Pointer.Visible = true;
series1.Pointer.Style = PointerStyles.Cross;
series1.Pointer.Color = Color.Red;
series2.Pointer.Style = PointerStyles.Star;
series2.Pointer.Color = Color.Blue;
series2.FillSampleValues();
series1.FillSampleValues();
}
Can you please, tell us which version of TeeChart.Net are you using? If you using last version please modify the code so we can reproduce your problem.
Thanks,
Re: pointer color style
Posted: Mon Oct 03, 2011 6:23 pm
by 14051412
Hi Sandra
I'm using the version for visual studio 2008 (teechart v3).
and i have tested the code you gave me, but it doesnt work in my version.
how i can solve this problem?
Thankyou
Re: pointer color style
Posted: Tue Oct 04, 2011 1:40 pm
by 10050769
Hello lolo,
Seems there are some changes in version 4 respect to version 3. If you want change color of your pointer in last version 3 of TeeChart.Net, you must change Color.Pen property of pointer. As do in following lines:
Code: Select all
series1.Pointer.Pen.Color = Color.Red;
series2.Pointer.Pen.Color = Color.Blue;
Can you please, tell us if your problem is solved, using previous lines of code?
I hope will helps.
Thanks,
Re: pointer color style
Posted: Thu Oct 06, 2011 4:50 pm
by 14051412
HI Sandra
I Have made what you told me, and it works perfectly.
Thankyou
Re: pointer color style
Posted: Fri Oct 07, 2011 7:05 am
by 10050769
Hello lolo,
I am glad that solution I suggest works for your
.
Thanks,