This is a migrated thread and some comments may be shown as answers.

AreaSeries can not add into RadCartesianChart.Series collection

1 Answer 108 Views
ChartView
This is a migrated thread and some comments may be shown as answers.
Chen
Top achievements
Rank 1
Chen asked on 19 Aug 2020, 04:55 AM

Hello , I'm trying package"Telerik.UI.for.Wpf.NetCore.Xaml.Trial" v2020.2.617, when I start to learn chartview,The VisualStudio can't build the project.

Here's the message:

"D:\Work\CSharp\PersonalProject\TelerikDemo\TelerikWpfApp1\TelerikWpfApp1\MainWindow.xaml(79,22): error MC3074: XML 命名空间“http://schemas.telerik.com/2008/xaml/presentation”中不存在标记“AreaSeries.DataPoints”。 行 79 位置 22."

Please give me a hand.

 

 

1 Answer, 1 is accepted

Sort by
0
Chen
Top achievements
Rank 1
answered on 19 Aug 2020, 07:06 AM

I got it.

There are two AreaSeries classes in  xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation"

So ambiguous AreaSeries detected.

After I add a specific reference

    xmlns:telerikC="clr-namespace:Telerik.Windows.Controls.ChartView;assembly=Telerik.Windows.Controls.Chart"

and then place 

 

<telerik:RadCartesianChart Grid.Column="1" Palette="Windows8">
    <telerik:RadCartesianChart.HorizontalAxis>
        <telerik:CategoricalAxis/>
    </telerik:RadCartesianChart.HorizontalAxis>
    <telerik:RadCartesianChart.VerticalAxis>
        <telerik:LinearAxis />
    </telerik:RadCartesianChart.VerticalAxis>
    <telerik:RadCartesianChart.Series>
        <telerikC:AreaSeries>
            <telerikC:AreaSeries.DataPoints>
                <telerik:CategoricalDataPoint Category="January" Value="2" />
                <telerik:CategoricalDataPoint Category="February" Value="5" />
                <telerik:CategoricalDataPoint Category="March" Value="3" />
                <telerik:CategoricalDataPoint Category="April" Value="10" />
                <telerik:CategoricalDataPoint Category="May" Value="9" />
                <telerik:CategoricalDataPoint Category="June" Value="7" />
                <telerik:CategoricalDataPoint Category="July" Value="1" />
            </telerikC:AreaSeries.DataPoints>
        </telerikC:AreaSeries>
    </telerik:RadCartesianChart.Series>
</telerik:RadCartesianChart>
Tags
ChartView
Asked by
Chen
Top achievements
Rank 1
Answers by
Chen
Top achievements
Rank 1
Share this question
or