Intersoft.Client.UI.Aqua.UXCollection Namespace > UXTreeView Class : CommandMemberPath Property |
<CategoryAttribute("Common Properties")> Public Property CommandMemberPath As String
Dim instance As UXTreeView Dim value As String instance.CommandMemberPath = value value = instance.CommandMemberPath
[CategoryAttribute("Common Properties")] public string CommandMemberPath {get; set;}
[CategoryAttribute("Common Properties")] public: property String^ CommandMemberPath { String^ get(); void set ( String^ value); }
You can bind a collection of data to UXTreeView by using HierarchicalDataTemplate to visualize the data in hierarchical manner. You use the ItemsSource and ItemTemplate property to specify the source and template of each level of data contained in the UXTreeView. If you do not want to differentiate the template of each level, you can create a generic style for UXTreeViewItem and assign it to the ItemContainerStyle property of the UXTreeView control. To learn more about data binding, see Data Binding Overview.
To bind the data, you can either use ItemTemplate such as HierarchicalDataTemplate, or the member path properties such as listed below.
The following example shows how to perform binding to UXTreeView using the member path properties.
XAML |
Copy Code
|
---|---|
<Grid> <Intersoft:UXTreeView ItemsSource="{Binding Files}" DisplayMemberPath="Name" CollectionMemberPath="Files" ImageMemberPath="Icon" AutoSelectMode="Expand" NavigateUriMemberPath="NavigateUri"> <Intersoft:UXTreeView.ItemContainerStyle> <Style TargetType="Intersoft:UXTreeViewItem"> <Setter Property="DisplayMemberPath" Value="Name" /> <Setter Property="ImageMemberPath" Value="Icon" /> <Setter Property="CollectionMemberPath" Value="Files" /> <Setter Property="DisplayMode" Value="ContentAndImage" /> <Setter Property="NavigateUriMemberPath" Value="NavigateUri" /> </Style> </Intersoft:UXTreeView.ItemContainerStyle> </Intersoft:UXTreeView> </Grid> |
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2