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. Image for the cookie policy date

Chart control hi low open low type chart

Hi,
I want to have the open close values shown as a circle instead of a horizontal line.Can you please help in achieving this.
Regards
Manu

2 Replies

MA Manu July 17, 2012 12:30 PM UTC

Hi,
I want to have the open close values shown as a circle instead of a horizontal line.Can you please help in achieving this.
Regards
Manu


VK Vijayabharathi K Syncfusion Team August 8, 2012 09:23 AM UTC

Hi Manu,

Thanks for using Syncfusion products.

We suggest you to use combination of Hilo and scatter type chart to achieve your requirement.   We are unable to set symbol for HiloOpenClose chart type. So, you can set desired symbol in Hilo and scatter chart type for your requirements. Please refer the below code snippet to achieve this,

[C#]

            // chart series for Hilo.           

            ChartSeries series1 = new ChartSeries("Series 1", ChartSeriesType.HiLo);

             series1.Points.Add(1, new double[] { 8, 3 });

            series1.Points.Add(2, new double[] { 10, 2 });

            series1.Points.Add(3, new double[] { 16, 2 });

            series1.Points.Add(4, new double[] { 7, 3 });

            series1.Points.Add(5, new double[] { 12, 3 });

            this.chartControl1.Series.Add(series1);

            // symbol for Hilo chart type

            series1.Style.Symbol.Shape = ChartSymbolShape.HorizLine;

            series1.Style.Symbol.Color = Color.CadetBlue;

            series1.Style.Interior = new BrushInfo(Color.Black);

 

              // chart series for scatter.           

            ChartSeries series2 = new ChartSeries("Series 2", ChartSeriesType.Scatter);

            for (int i = 0; i < 5; i++)

                series2.Points.Add(i+1, (series1.Points[i].YValues[0] + series1.Points[i].YValues[1]) / 2);

            this.chartControl1.Series.Add(series2);

              // symbol for scatter chart type

            series2.Style.Interior = new BrushInfo(Color.LightGreen);

            series2.ZOrder = 0;

 

              // chart series for scatter.           

            ChartSeries series3 = new ChartSeries("Series 3", ChartSeriesType.Scatter);

             for (int i = 0; i < 5; i++)

                series3.Points.Add(i + 1, (series1.Points[i].YValues[1]));

            this.chartControl1.Series.Add(series3);

           // symbol for scatter chart type

            series3.Style.Symbol.Shape = ChartSymbolShape.HorizLine;

            series3.Style.Symbol.Color = Color.Red;

Please let us know if any concerns

Regards,

Vijayabharathi

 


Loader.
Live Chat Icon For mobile
Up arrow icon