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 : Nov 16th 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Dotted or dashed ChartStripLine

Thread ID:

Created:

Updated:

Platform:

Replies:

118764 Apr 8,2015 12:54 PM UTC Apr 10,2015 10:43 AM UTC WinRT 4
loading
Tags: SfChart
Jesus Perez Valle
Asked On April 8, 2015 12:54 PM UTC

Hello,

I need to represent a dotted or dashed Horizontal ChartStripLine inside a sfChart.

In this forum I have seen two workarounds to this problem but unfortunately no one satisfy my needs.

The first one is a solution for MVC where the rect elements of the ChartStripLine are replaced with other xaml element via javascript (I am not sure if this solution is feasible via C#?)
The second one is to use a LineSeries with its own ObservableCollection instead the ChartStripLine ( That means I need to create an ObservableCollection where all the elements have the same value, which I do not find elegant at all).

Am I wrong in my arguments? Is there any alternative workaround?

Thank you very much

Sumathi Jayaraj [Syncfusion]
Replied On April 9, 2015 05:38 AM UTC

Hi Perez,

Thank you for contacting Syncfusion support.

We have drawn stripline as a rectangle and there are no support to customize the stripline as a dotted or dashed line. Alternatively, we can use the horizontal or vertical line annotation to represent the dashed line for your requirement. We have prepared a sample based on your requirement and please find the sample in the below location.

Sample: StriplineSample.zip

Please let us know if you have any queries.

Regards,
Sumathi J

Jesus Perez Valle
Replied On April 9, 2015 07:33 AM UTC

Wonderful, that is exactly what I need.

Thank you very much!

Jesus Perez Valle
Replied On April 9, 2015 09:59 AM UTC

After integrating horizontal line annotations in my project, I would like to ask two questions:

- When the HorizontalLineAnnotation  crosses my data series, it hides the data. Is it possible to have the HorizontalLineAnnotation in Background?
- For readability reasons, I would like to have the Axis Labels of the vertical axis on the left side of the chart and the AxisLabel of the HorizontalLineAnnotation on the right side. Is this possible by editing the AxisLabel of the HorizontalLineAnnotation DataTemplate?

Thanks in advance

Sumathi Jayaraj [Syncfusion]
Replied On April 10, 2015 10:43 AM UTC

Hi Jesus,

Thanks for the update.

Query 1: Is it possible to have the HorizontalLineAnnotation in Background?

We would like to let you know that by default, Annotations are placed on the top of the series. However we have achieved your requirement in a workaround by overriding the SfChart and placed the annotation canvas in the bottom of the chart.

Query 2: I would like to have the Axis Labels of the vertical axis on the left side of the chart and the AxisLabel of the HorizontalLineAnnotation on the right side.

We are not having the direct API to display AxisLabels of Annotation in the opposite position of ChartAxis (i.e., right side). Alternatively, we have defined two YAxis to display the axis label of annotation in right side.

Query 3: Is this possible by editing the AxisLabel of the HorizontalLineAnnotation Data Template?

We are able to customize the AxisLabel of the Annotation by using “AxisLabelTemplate”.

We have modified the sample based on your requirements and it can be downloaded from the below location.

Sample: StriplineSample.zip

Please refer the below link for more information of Annotations

Link: http://help.syncfusion.com/ug/wpf/Documents/annotations.htm

Please let us know if you need any further assistance on this.

Regards,
Sumathi J

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

;