when my X Axis is of a time int it works perfectly. But when i put it as a string an error occurs("Input string was not in a correct format")
My XAML is like this
and my code behing is like this
where MyClass is like this
My XAML is like this
<
telerik:RadChart
Name
=
"radChartCAMois"
>
<
telerik:RadChart.SeriesMappings
>
<
telerik:SeriesMapping
LegendLabel
=
"Chiffre d'affaire en DT"
>
<
telerik:SeriesMapping.SeriesDefinition
>
<
telerik:Area3DSeriesDefinition
/>
</
telerik:SeriesMapping.SeriesDefinition
>
<
telerik:SeriesMapping.ItemMappings
>
<
telerik:ItemMapping
DataPointMember
=
"XValue"
FieldName
=
"IntValue"
></
telerik:ItemMapping
>
<
telerik:ItemMapping
DataPointMember
=
"YValue"
FieldName
=
"StringValue"
></
telerik:ItemMapping
>
</
telerik:SeriesMapping.ItemMappings
>
</
telerik:SeriesMapping
>
</
telerik:RadChart.SeriesMappings
>
</
telerik:RadChart
>
and my code behing is like this
List<MyClass> a =
new
List<MyClass>{
new
MyClass{intValue = 1,stringValue =
"s1"
},
new
MyClass{intValue = 2,stringValue =
"s2"
}};
radChartCAMois.ItemsSource = a;
where MyClass is like this
class
MyClass
{
public
int
intValue;
public
string
stringValue;
}