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

Problem of the curve drawing by SplineAreaSeries

Hi
I'm using the SplineAreaSeries in my UWP APP to demonstrate data in ten days. But I encountered a problem when the control plot the data. Below is the ideal image plotted if the data bound to the control is "good"

However, if the data is not so good, for instance the y value of the ten days are 40, 0, 0, 0, 0, 0, 0, 20, 20, 0, the image plotted is very strange

Because the data is "sharp" so the control cannot draw the curve properly. Is there any solution to solve this?  Following is the xaml code for this page:

        <Grid Background="{ThemeResource ApplicationPageBackgroundThemeBrush}" Name="GreenStarGrid">
            <Grid Background="#F4F4F4">
                <chart:SfChart HorizontalAlignment="Stretch" VerticalAlignment="Stretch" AreaBorderBrush="#00000000" Palette="Custom" >
                    <chart:SfChart.ColorModel>
                        <chart:ChartColorModel>
                            <chart:ChartColorModel.CustomBrushes>
                                <SolidColorBrush Color="#7F71BC56"/>
                            </chart:ChartColorModel.CustomBrushes>
                        </chart:ChartColorModel>
                    </chart:SfChart.ColorModel>
                    <chart:SfChart.PrimaryAxis>
                        <chart:DateTimeAxis EdgeLabelsDrawingMode="Shift" Interval="1" IntervalType="Days" Header="" LabelFormat="dd" ShowOrigin="False" ShowAxisNextToOrigin="False" MajorTickLineStyle="{StaticResource TickLine}"/>
                    </chart:SfChart.PrimaryAxis>
                    <chart:SfChart.SecondaryAxis>
                        <chart:NumericalAxis Visibility="Collapsed" Header="" ShowGridLines="False" ShowOrigin="False" ShowAxisNextToOrigin="False" MajorTickLineStyle="{StaticResource TickLine}"/>
                    </chart:SfChart.SecondaryAxis>
                    <chart:SplineAreaSeries ItemsSource="{x:Bind green_star_list}" XBindingPath="Date" YBindingPath="PointHardEarned" Name="GreenStarAreaLine">
                        <chart:SplineAreaSeries.AdornmentsInfo>
                            <chart:ChartAdornmentInfo  LabelPosition="Auto" SegmentLabelContent="YValue" ShowMarker="True" Symbol="Custom" ShowLabel="True" SymbolTemplate="{StaticResource MarkerTemplateGreen}" LabelTemplate="{StaticResource LabelTemplateGreen}">
                            </chart:ChartAdornmentInfo>
                        </chart:SplineAreaSeries.AdornmentsInfo>
                    </chart:SplineAreaSeries>
                </chart:SfChart>
            </Grid>
        </Grid>

1 Reply

SJ Sumathi Jayaraj Syncfusion Team February 18, 2016 04:25 PM UTC

Hi Albert,

Thanks for contacting Syncfusion support.

"Bezier curve" is used to render spline area series. This is the behavior of bezier curve. Area series is renders straight line for zero values.

Regards,
Sumathi J

Loader.
Up arrow icon