I use listview store parent and child description but there doesn't show in treeView.
Can use list to store treeview data instead of use class inherited?
XAML
<syncfusion:SfTreeView x:Name="treeView" ItemsSource="{Binding treeView}" ItemHeight="40" ExpanderWidth="40" Indentation="20"
IsAnimationEnabled="true" FullRowSelect="True" >
<sfTreeView:SfTreeView.HierarchyPropertyDescriptors>
<treeviewengine:HierarchyPropertyDescriptor TargetType="{x:Type local:TreeView}" ChildPropertyName= "childDesc"/>
</sfTreeView:SfTreeView.HierarchyPropertyDescriptors>
<sfTreeView:SfTreeView.ItemTemplate>
<DataTemplate>
<Grid Padding="5,0,0,0" BackgroundColor="Transparent">
<Label Text="{Binding parentDesc}" TextColor="Black" FontSize="Medium" VerticalTextAlignment="Center"/>
</Grid>
</DataTemplate>
</sfTreeView:SfTreeView.ItemTemplate>
</syncfusion:SfTreeView>
.CS
public List<TreeView> GetTreeView()
{
var TreeView = new List<TreeView>()
{
new TreeView(){parentDesc = "1Bedside"},
new TreeView(){parentDesc = "2", childDesc = "C2"},
new TreeView(){parentDesc = "3", childDesc = "C3"},
new TreeView(){parentDesc = "4", childDesc = "C4"},
new TreeView(){parentDesc = "5", childDesc = "C5"},
};
return TreeView;
}