We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Drawing StripLines on a chart

Thread ID:

Created:

Updated:

Platform:

Replies:

27544 Apr 14,2005 07:06 AM UTC Apr 14,2005 02:21 PM UTC WinForms 1
loading
Tags: Chart
Orit Dermer
Asked On April 14, 2005 07:06 AM UTC

I''m trying to draw a range on the Y axis of my chart. The type of numbers on this axis is double. and the scale is between 0 to 500. I need the range to be between 200 to 300. Thanks, Orit

Davis Jebaraj [Syncfusion]
Replied On April 14, 2005 02:21 PM UTC

Hi, Please find the attached sample for an implementation of a StripLine along the Y axis: ChartStripLineYAxis_7593.zip The releavnt code is also shown below: private ChartStripLine optimalZone = new ChartStripLine(); private void CreateStripLine() { optimalZone.Enabled = true; optimalZone.Vertical = false; optimalZone.StartAtAxisPosition = false; optimalZone.Start = 200; optimalZone.End = 300; optimalZone.Width = 100; optimalZone.Period = 100; optimalZone.Text = "Optimal"; optimalZone.Font = new Font(optimalZone.Font.FontFamily.Name,18); optimalZone.TextColor = Color.CadetBlue; optimalZone.Interior = new BrushInfo(100, new BrushInfo(GradientStyle.Vertical,Color.Red , Color.Red )); } private void SetStripLine() { if(this.checkBox1.Checked) this.chartControl1.PrimaryYAxis.StripLines.Add(optimalZone); else this.chartControl1.PrimaryYAxis.StripLines.Remove(optimalZone); } Thanks, Davis

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

;