Hello Berry,
You can use the PointTemplate property of the series to define its visual element. For example:
To add this in code you can define the template in XAML and get it through the Resources' dictionary of the view:
Or you can define the template as string and use the XamlReader.Parse() method.
I hope this is useful.
Regards,
Martin
Telerik
You can use the PointTemplate property of the series to define its visual element. For example:
<
telerik:LineSeries.PointTemplate
>
<
DataTemplate
>
<
Ellipse
Fill
=
"Red"
Width
=
"10"
Height
=
"10"
/>
</
DataTemplate
>
</
telerik:LineSeries.PointTemplate
>
<
Window.Resources
>
<
DataTemplate
x:Key
=
"pointTemplate"
>
<
Ellipse
Fill
=
"Red"
Width
=
"10"
Height
=
"10"
/>
</
DataTemplate
>
</
Window.Resources
>
series.PointTemplate = (DataTemplate)
this
.Resources[
"pointTemplate"
];
Or you can define the template as string and use the XamlReader.Parse() method.
string
pointTemplateString = @
"<DataTemplate xmlns="
"http://schemas.microsoft.com/winfx/2006/xaml/presentation"
" xmlns:x="
"http://schemas.microsoft.com/winfx/2006/xaml"
">"
+
@
"<Ellipse Fill="
"Red"
" Width="
"10"
" Height="
"10"
" /></DateTemplate>"
;
series.PointTemplate = (DataTemplate)XamlReader.Parse(pointTemplateString);
I hope this is useful.
Regards,
Martin
Telerik
Do you want to have your say when we set our development plans?
Do you want to know when a feature you care about is added or when a bug fixed?
Explore the
Telerik Feedback Portal
and vote to affect the priority of the items