LeafLabelPath in UWP TreeMap (SfTreeMap)

18 Nov 20181 minute to read

LeafLabelPath of SfTreeMap is a path to a field on the source object, which serves as the “label” of the object.

Code Sample:

  • XAML
  • <Grid Background="{StaticResource ApplicationPageBackgroundThemeBrush}">
    
        <Grid.DataContext>
            <local:PopulationViewModel/>
        </Grid.DataContext>
    
        <syncfusion:SfTreeMap ItemsSource="{Binding PopulationDetails}"
                              LeafLabelPath="Country"/>
    
    </Grid>

    NOTE

    The specified field must be available in each and every sub class (object) defined in hierarchical (nested) data collection.