syncfusion-wpf-treegrid — independently scanned and version-tracked by SaferSkills.
SaferSkills independently audited syncfusion-wpf-treegrid (Agent Skill) and scored it 100/100 (green). The audit ran 55 deterministic rules across Security, Supply Chain, Maintenance, Transparency, and Community; it found 0 high-severity and 0 lower-severity findings. The full rule-by-rule trace and per-finding evidence are below. Free, methodology-open.
Findings & checks · 0 flagged
Every scanned point with the score it earned and what moved between them.
First recorded scan — no prior version to compare against.
The primary manifest — the file an agent reads to learn what this artifact does.
Comprehensive guide for implementing the Syncfusion® WPF TreeGrid control - a data-oriented control that displays self-relational and hierarchical data in a tree structure with columns. This skill provides complete guidance for setup, data binding, column configuration, interactive features, data operations, styling, and advanced capabilities.
Use this skill when you need to:
This skill is essential for any WPF application that needs to present hierarchical or parent-child data in an interactive, feature-rich grid interface.
The SfTreeGrid control provides:
📄 Read: references/getting-started.md
Start here for initial setup and basic implementation:
Data Binding Approaches 📄 Read: references/data-binding.md
Load-On-Demand 📄 Read: references/load-on-demand.md
Column Basics 📄 Read: references/columns.md
Column Types 📄 Read: references/column-types.md
Column Sizing 📄 Read: references/column-sizing.md
Editing 📄 Read: references/editing.md
Data Validation 📄 Read: references/data-validation.md
Selection 📄 Read: references/selection.md
Cell Merging 📄 Read: references/merge-cells.md
Sorting 📄 Read: references/sorting.md
Filtering 📄 Read: references/filtering.md
Conditional Styling 📄 Read: references/conditional-styling.md
Styles and Templates 📄 Read: references/styles-and-templates.md
Export and Printing 📄 Read: references/export-and-printing.md
Advanced Configuration 📄 Read: references/advanced-features.md
<Window x:Class="TreeGridSample.MainWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:syncfusion="http://schemas.syncfusion.com/wpf">
<syncfusion:SfTreeGrid Name="treeGrid"
AutoGenerateColumns="True"
ChildPropertyName="Children"
ItemsSource="{Binding Employees}"
AllowSorting="True"
AllowFiltering="True"
AllowEditing="True">
</syncfusion:SfTreeGrid>
</Window>using Syncfusion.UI.Xaml.TreeGrid;
using System.Collections.ObjectModel;
namespace TreeGridSample
{
public class Employee
{
public int EmployeeID { get; set; }
public string FirstName { get; set; }
public string LastName { get; set; }
public string Title { get; set; }
public int ReportsTo { get; set; }
public ObservableCollection<Employee> Children { get; set; }
public Employee()
{
Children = new ObservableCollection<Employee>();
}
}
public class EmployeeViewModel
{
public ObservableCollection<Employee> Employees { get; set; }
public EmployeeViewModel()
{
Employees = new ObservableCollection<Employee>();
PopulateData();
}
private void PopulateData()
{
var ceo = new Employee
{
EmployeeID = 1,
FirstName = "Robert",
LastName = "King",
Title = "CEO"
};
ceo.Children.Add(new Employee
{
EmployeeID = 2,
FirstName = "David",
LastName = "Smith",
Title = "VP of Sales",
ReportsTo = 1
});
ceo.Children.Add(new Employee
{
EmployeeID = 3,
FirstName = "Nancy",
LastName = "Davolio",
Title = "VP of Marketing",
ReportsTo = 1
});
Employees.Add(ceo);
}
}
}For data where parent-child relationship exists within the same collection:
public class Task
{
public int TaskID { get; set; }
public string TaskName { get; set; }
public int? ParentID { get; set; } // Nullable for root items
}
// ViewModel
public ObservableCollection<Task> Tasks { get; set; }<syncfusion:SfTreeGrid Name="treeGrid"
ItemsSource="{Binding Tasks}"
ParentPropertyName="ParentID"
SelfRelationRootValue="-1"
ChildPropertyName="TaskID">
</syncfusion:SfTreeGrid>For data with explicit child collections:
public class Folder
{
public string FolderName { get; set; }
public ObservableCollection<Folder> SubFolders { get; set; }
}<syncfusion:SfTreeGrid Name="treeGrid"
ItemsSource="{Binding Folders}"
ChildPropertyName="SubFolders">
</syncfusion:SfTreeGrid>For large datasets where child nodes load when parent expands:
treeGrid.RequestTreeItems += TreeGrid_RequestTreeItems;
private void TreeGrid_RequestTreeItems(object sender, TreeGridRequestTreeItemsEventArgs e)
{
if (e.ParentItem == null)
{
// Load root nodes
e.ChildItems = GetRootNodes();
}
else
{
// Load child nodes for expanded parent
var parent = e.ParentItem as BusinessObject;
e.ChildItems = GetChildNodes(parent.ID);
}
}<syncfusion:SfTreeGrid ItemsSource="{Binding Employees}"
AutoGenerateColumns="False">
<syncfusion:SfTreeGrid.Columns>
<syncfusion:TreeGridTextColumn HeaderText="Name"
MappingName="FirstName"
Width="150"/>
<syncfusion:TreeGridNumericColumn HeaderText="Age"
MappingName="Age"
NumberDecimalDigits="0"/>
<syncfusion:TreeGridDateTimeColumn HeaderText="DOB"
MappingName="DateOfBirth"
Pattern="ShortDate"/>
<syncfusion:TreeGridCheckBoxColumn HeaderText="Active"
MappingName="IsActive"/>
</syncfusion:SfTreeGrid.Columns>
</syncfusion:SfTreeGrid><syncfusion:SfTreeGrid ItemsSource="{Binding Employees}"
ChildPropertyName="Children">
<syncfusion:SfTreeGrid.RecordContextMenu>
<ContextMenu>
<MenuItem Header="Add Child"
Command="{Binding AddChildCommand}"
CommandParameter="{Binding}"/>
<MenuItem Header="Delete"
Command="{Binding DeleteCommand}"
CommandParameter="{Binding}"/>
</ContextMenu>
</syncfusion:SfTreeGrid.RecordContextMenu>
</syncfusion:SfTreeGrid>public class EmployeeViewModel : INotifyPropertyChanged
{
public ICommand AddChildCommand { get; set; }
public ICommand DeleteCommand { get; set; }
public EmployeeViewModel()
{
AddChildCommand = new RelayCommand(AddChild);
DeleteCommand = new RelayCommand(Delete);
}
private void AddChild(object parameter)
{
var parent = parameter as Employee;
if (parent != null)
{
parent.Children.Add(new Employee { /* ... */ });
}
}
}| Property | Type | Description |
|---|---|---|
| ItemsSource | IEnumerable | Data source for the TreeGrid |
| ChildPropertyName | string | Property name for child collection |
| ParentPropertyName | string | Property name for parent ID (self-relational) |
| SelfRelationRootValue | object | Value indicating root level nodes |
| AutoGenerateColumns | bool | Auto-generate columns from data source |
| Columns | TreeGridColumns | Collection of column definitions |
| Property | Type | Description |
|---|---|---|
| AllowEditing | bool | Enable/disable cell editing |
| AllowSorting | bool | Enable/disable sorting |
| AllowFiltering | bool | Enable/disable filtering |
| FilterLevel | FilterLevel | Filtering scope (Root, All, Extended) |
| SelectionMode | GridSelectionMode | Selection mode (Single, Multiple, Extended) |
| SelectionUnit | GridSelectionUnit | Selection unit (Row, Cell, Any) |
| AutoExpandMode | AutoExpandMode | Auto-expand behavior (RootNodesExpanded, AllNodesExpanded) |
| ExpanderPosition | ExpanderPosition | Position of expand/collapse icon (Start, End) |
| Property | Type | Description |
|---|---|---|
| GridLinesVisibility | GridLinesVisibility | Grid lines display (Both, Horizontal, Vertical, None) |
| ColumnSizer | GridLengthUnitType | Column auto-sizing strategy |
| RowHeight | double | Height of each row |
| HeaderRowHeight | double | Height of header row |
| IndentColumnWidth | double | Width of indent for each level |
Display organizational structure with employees, managers, and departments in expandable tree format.
Show folders and files in hierarchical structure with load-on-demand for large directory trees.
Display projects, sub-projects, tasks, and subtasks with status tracking, editing, and conditional styling.
Show product assemblies with components, sub-components, quantities, and costs in hierarchical view.
Display product categories, subcategories, and products with filtering, sorting, and export capabilities.
Financial account trees with parent-child relationships, balance calculations, and drill-down capabilities.
Track approval hierarchies with status indicators, conditional styling, and interactive editing.
Display countries, states, cities in hierarchical format with data visualization and export features.
Next Steps: Navigate to the specific reference file above based on your implementation needs. Start with getting-started.md for initial setup, then explore data binding, column configuration, and advanced features as needed.
~30 seconds. Free. No account. Every finding cites a rule and a line of evidence.