TreeDataGrid combines tree navigation and tabular columns in a single control. In the v12-style API there are two supported ways to configure it:
ItemsSource plus declarative TreeDataGrid*Column elements in XAMLSource plus a FlatTreeDataGridSource<TModel> or HierarchicalTreeDataGridSource<TModel> built in codeItemsSource when you want the control definition to stay in XAML and you do not need advanced source-only features.Source when you need filtering, programmatic expand/collapse, or more involved runtime composition.ItemsSource: binds a collection for declarative XAML columnsSource: binds a FlatTreeDataGridSource<TModel> or HierarchicalTreeDataGridSource<TModel>SelectionMode: chooses row or cell selection, with optional multiple selectionCanUserResizeColumns: controls column resizing, default falseCanUserSortColumns: controls header-click sorting, default true