How to display pointers only selected points on the series?

TeeChart for Microsoft Visual Studio .NET, Xamarin Studio (Android, iOS & Forms) & Monodevelop.
Post Reply
Lakshmi
Newbie
Newbie
Posts: 40
Joined: Fri Oct 07, 2005 4:00 am
Location: India
Contact:

How to display pointers only selected points on the series?

Post by Lakshmi » Thu Feb 09, 2006 7:27 am

I have a form which has t-chart control on it.
And i have added a line series to the t-chart control and added few points in the line series.

Now i have a requirement to show pointers for couple of points on the series.
By doing
this.line1.Pointer.Visible = true;
This will display pointers for all the points on the series.

Narcís
Site Admin
Site Admin
Posts: 14730
Joined: Mon Jun 09, 2003 4:00 am
Location: Banyoles, Catalonia
Contact:

Post by Narcís » Thu Feb 09, 2006 10:34 am

Hi Lakshmi,

Yes, you can easily do that using the OnGetPointerStyle event as shown here:

Code: Select all

		private void Form1_Load(object sender, System.EventArgs e)
		{
			line1.FillSampleValues();

			line1.Pointer.Visible=true;
		}

		private void line1_GetPointerStyle(Steema.TeeChart.Styles.CustomPoint series, Steema.TeeChart.Styles.CustomPoint.GetPointerStyleEventArgs e)
		{
			if (series.YValues[e.ValueIndex]%2==0)
			{
				e.Style=Steema.TeeChart.Styles.PointerStyles.Nothing;
			}
		}
Best Regards,
Narcís Calvet / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Image Image Image Image Image Image
Instructions - How to post in this forum

Post Reply