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

How can I add a SparkLine column to a SfDataGrid?

Thread ID:





124397 Jun 7,2016 11:01 AM UTC Jun 8,2016 08:40 AM UTC WPF 1
Tags: SfDataGrid
Asked On June 7, 2016 11:01 AM UTC

For example, I have a class named "Row":
public class Row
    public string Name { get; set; }
    public ObservableCollection<double> DataPoints { get; set; }
I want to display multiple rows in SfDataGrid. Each row should contain a SparkLine to display DataPoints. How can I bind it in XAML?

Jai Ganesh S [Syncfusion]
Replied On June 8, 2016 08:40 AM UTC

Hi Ivan, 
You can add the SparkLine inside the GridTemplateColumn in SfDataGrid like below, 
<syncfusion:GridTemplateColumn MappingName="EmployeeGrade" Width="150" > 
                                <syncfusion:SfLineSparkline ItemsSource="{Binding EmployeeGrade}"  MarkerVisibility="Visible" 
                                                               Padding="4" YBindingPath="GradePercentage"> 
Screen Shot: 
Jai Ganesh S 


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.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

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